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 static char USMID[] = "\n@(#)5.0_pl/sources/cmd_line.c 5.16 10/20/99 17:17:46\n";
00038
00039 #include <unistd.h>
00040 #if defined(__linux__)
00041 # include <getopt.h>
00042 #endif
00043
00044 # include "defines.h"
00045
00046 # include "host.m"
00047 # include "host.h"
00048 # include "target.m"
00049 # include "target.h"
00050
00051 # include "globals.m"
00052 # include "tokens.m"
00053 # include "sytb.m"
00054 # include "src_input.m"
00055 # include "cmd_line.m"
00056 # include "debug.m"
00057
00058 # include "globals.h"
00059 # include "tokens.h"
00060 # include "sytb.h"
00061 # include "cmd_line.h"
00062
00063
00064
00065
00066
00067 extern char release_level[];
00068 extern char frontend_version[];
00069
00070
00071 static void dump_help_screen (void);
00072 static void init_cmd_line (void);
00073 static void process_A_option (char *);
00074 static void process_a_option (char *);
00075 static void process_b_option (char *);
00076 static void process_C_option (char *, char *[]);
00077 static void process_d_option (char *);
00078 static void process_e_option (char *);
00079 static void process_f_option (char *);
00080 static void process_G_option (char *);
00081 static void process_i_option (char *);
00082 static void process_J_option (char *);
00083 static void process_k_option (char *);
00084 static void process_m_option (char *);
00085 static void process_M_option (char *);
00086 static void process_N_option (char *);
00087 static void process_O_option (char *, int);
00088 static void add_to_fp_table (char *, int *, int);
00089 static void process_P_option (char *);
00090 static void process_q_option (char *);
00091 static void process_r_option (char *);
00092 static void process_R_option (char *);
00093 static void process_s_option (char *);
00094 static void process_S_option (char *);
00095 static void process_t_option (char *);
00096 static void process_u_option (char *);
00097 static void process_v_option (char *);
00098 static void process_x_option (char *);
00099 static void process_X_option (char *);
00100 static void process_Y_option (char *);
00101 static void set_prog_file_names (char *argv[]);
00102 static void validate_O_option (void);
00103 static void validate_G_option (void);
00104 static void validate_R_option (void);
00105 static void validate_s_option (void);
00106 static void process_D_option(char *);
00107 static void process_U_option(char *);
00108 extern void process_v_dbg_flags(char *);
00109 static void set_system_module_path( void );
00110 static void process_reshape_array(char *);
00111 static void dump_options(void);
00112
00113
00114
00115
00116
00117
00118
00119
00120
00121
00122
00123
00124
00125
00126
00127
00128
00129
00130
00131
00132 int process_cmd_line(int argc,
00133 char *argv[])
00134 {
00135 char err_char;
00136 int err_ind;
00137 int option;
00138 int i;
00139
00140 int save_argc;
00141
00142
00143
00144
00145
00146
00147
00148
00149
00150
00151
00152
00153 char *opt_string="a:b:d:e:f:ghi:k:m:p:q:r:s:t:u:v:x:z"
00154 "A:C:D:FG:I:J:M:N:O:P:R:S:T:U:Y:X:VZ";
00155
00156 char str[7];
00157
00158
00159 TRACE (Func_Entry, "process_cmd_line", NULL);
00160
00161 save_argc = argc;
00162
00163 opterr = 0;
00164
00165 init_cmd_line ();
00166
00167 # ifdef _DEBUG
00168 # ifdef _ENABLE_FEI
00169 str[0] = 'N';
00170 str[1] = '\0';
00171 process_v_dbg_flags (str);
00172 # endif
00173 # endif
00174 err_ind = optind;
00175
00176 while ((option = getopt (argc, argv, opt_string)) != EOF) {
00177
00178 switch (option) {
00179 case 'h':
00180 dump_options();
00181 return 1;
00182 break;
00183 case 'a':
00184 process_a_option (optarg);
00185 break;
00186
00187 case 'b':
00188 process_b_option (optarg);
00189 break;
00190
00191 case 'd':
00192 process_d_option (optarg);
00193 break;
00194
00195 case 'e':
00196 process_e_option (optarg);
00197 break;
00198
00199 case 'f':
00200 process_f_option (optarg);
00201 break;
00202
00203 case 'g':
00204 cmd_line_flags.debug_lvl = Debug_Lvl_0;
00205 break;
00206
00207 case 'i':
00208 process_i_option (optarg);
00209 break;
00210
00211 case 'k':
00212 process_k_option (optarg);
00213 break;
00214
00215
00216
00217
00218
00219
00220
00221
00222 case 'm':
00223 process_m_option (optarg);
00224 break;
00225
00226 case 'O':
00227 process_O_option (optarg, argc);
00228 break;
00229
00230 case 'p':
00231 add_to_fp_table (optarg, &module_path_idx, option);
00232 break;
00233
00234 case 'q':
00235 process_q_option (optarg);
00236 break;
00237
00238 case 'r':
00239 process_r_option (optarg);
00240 break;
00241
00242 case 'R':
00243 process_R_option (optarg);
00244 break;
00245
00246 case 's':
00247 process_s_option (optarg);
00248 break;
00249
00250 case 'S':
00251 process_S_option (optarg);
00252 break;
00253
00254 case 't':
00255 process_t_option (optarg);
00256 break;
00257
00258 case 'u':
00259 process_u_option (optarg);
00260 break;
00261
00262 case 'v':
00263 process_v_option (optarg);
00264 break;
00265
00266 case 'A':
00267 process_A_option (optarg);
00268 break;
00269
00270 case 'C':
00271 process_C_option (optarg, argv);
00272 break;
00273
00274 case 'D':
00275 # ifdef _FRONTEND_CONDITIONAL_COMP
00276 process_D_option (optarg);
00277 # endif
00278 break;
00279
00280 case 'x':
00281 process_x_option (optarg);
00282 break;
00283
00284 case 'F':
00285 # ifdef _FRONTEND_CONDITIONAL_COMP
00286 cmd_line_flags.pp_macro_expansion = TRUE;
00287 on_off_flags.preprocess = TRUE;
00288 # endif
00289 break;
00290
00291
00292 case 'G':
00293 process_G_option (optarg);
00294 break;
00295
00296 case 'I':
00297 add_to_fp_table(optarg, &include_path_idx, option);
00298 break;
00299
00300 case 'J':
00301 process_J_option (optarg);
00302 break;
00303
00304 case 'M':
00305 process_M_option (optarg);
00306 break;
00307
00308 case 'N':
00309 process_N_option (optarg);
00310 break;
00311
00312 case 'P':
00313 process_P_option (optarg);
00314 break;
00315
00316 case 'U':
00317 # ifdef _FRONTEND_CONDITIONAL_COMP
00318 process_U_option (optarg);
00319 # endif
00320 break;
00321
00322 case 'V':
00323 cmd_line_flags.verify_option = TRUE;
00324 break;
00325
00326 case 'X':
00327 process_X_option (optarg);
00328 break;
00329
00330 case 'Y':
00331 process_Y_option (optarg);
00332 break;
00333
00334 # ifdef COARRAY_FORTRAN
00335 case 'Z':
00336 cmd_line_flags.co_array_fortran = TRUE;
00337 dump_flags.f_minus_minus = TRUE;
00338 dump_flags.fmm1 = TRUE;
00339 break;
00340 # endif
00341
00342 case 'z':
00343 cmd_line_flags.cleanUpWhirl=1;
00344 break;
00345
00346
00347 default:
00348
00349 err_char = argv[err_ind][1];
00350
00351 if (err_char == 'O') {
00352
00353
00354
00355
00356 ntr_msg_queue(0, 1221, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
00357 }
00358 else {
00359 err_char = optopt;
00360 ntr_msg_queue(0, 77, Log_Error, 0,
00361 (char *) NULL, optopt, ARG_ARG);
00362 }
00363 break;
00364 }
00365
00366 err_ind = optind;
00367 }
00368
00369
00370
00371 if (dump_flags.help_dbg) {
00372 dump_help_screen();
00373 return 1;
00374 }
00375
00376
00377
00378 if (argc == 2 && cmd_line_flags.verify_option) {
00379
00380
00381
00382 }
00383 else {
00384
00385 if (on_off_flags.MPP_apprentice) {
00386 cif_flags = cif_flags | ALL_RECS |
00387 XREF_RECS | MISC_RECS |
00388 MESSAGE_RECS | INFO_RECS |
00389 BASIC_RECS | COMPILER_RECS;
00390 }
00391
00392 # if defined(GENERATE_WHIRL)
00393
00394 if (dump_flags.cray_compatible) {
00395 cmd_line_flags.s_default64 = TRUE;
00396 }
00397 # endif
00398
00399 if (on_off_flags.all_debug) {
00400
00401
00402
00403 opt_flags.support_lvl = 0;
00404 cmd_line_flags.debug_lvl = Debug_Lvl_0;
00405 on_off_flags.indef_init = TRUE;
00406 cmd_line_flags.msg_lvl_suppressed = Caution_Lvl;
00407 cmd_line_flags.runtime_argument = TRUE;
00408 cmd_line_flags.runtime_bounds = TRUE;
00409 cmd_line_flags.runtime_conformance = TRUE;
00410 cmd_line_flags.runtime_substring = TRUE;
00411 cmd_line_flags.runtime_ptr_chk = TRUE;
00412 cmd_line_flags.runtime_arg_call = TRUE;
00413 cmd_line_flags.runtime_arg_entry = TRUE;
00414 cif_flags = cif_flags | ALL_RECS |
00415 XREF_RECS | MISC_RECS |
00416 MESSAGE_RECS | INFO_RECS |
00417 BASIC_RECS | COMPILER_RECS;
00418 cif_C_opts = cif_C_opts | ALL_RECS;
00419
00420 if (on_off_flags.zero_init) {
00421 on_off_flags.zero_init = FALSE;
00422 ntr_msg_queue(0, 1313, Log_Warning, 0, "ei\ne0", 0,MULT_STR_ARG);
00423 }
00424
00425 if (! set_scalar_option) {
00426 opt_flags.scalar_lvl = Scalar_Lvl_0;
00427 }
00428
00429 # if defined(_ACCEPT_VECTOR)
00430
00431 if (! set_vector_option) {
00432 opt_flags.vector_lvl = Vector_Lvl_0;
00433 }
00434
00435 # endif
00436
00437 # if defined(_ACCEPT_TASK)
00438
00439 if (! set_task_option) {
00440 opt_flags.task_lvl = Task_Lvl_0;
00441 }
00442 # endif
00443
00444 # if defined(_ACCEPT_STREAM)
00445
00446 if (! set_stream_option) {
00447 opt_flags.stream_lvl = Stream_Lvl_0;
00448 }
00449
00450 # endif
00451 }
00452
00453
00454
00455 if (cmd_line_flags.debug_lvl < No_Debugging) {
00456 validate_G_option ();
00457 }
00458
00459 validate_O_option ();
00460 validate_R_option ();
00461 validate_s_option ();
00462
00463 if (cmd_line_flags.align32 && cmd_line_flags.align64) {
00464 cmd_line_flags.align32 = FALSE;
00465 ntr_msg_queue(0, 1353, Log_Warning, 0,
00466 "-a align32\n-a align64\n-a align32",
00467 0, MULT_STR_ARG);
00468 }
00469
00470 if (target_ieee) {
00471
00472 if (set_ieeeconform_option && opt_flags.ieeeconform &&
00473 !on_off_flags.eu) {
00474 on_off_flags.eu = FALSE;
00475
00476 if (set_eu_option) {
00477 ntr_msg_queue(0, 1215, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
00478 }
00479 else {
00480 ntr_msg_queue(0, 1216, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
00481 }
00482 }
00483
00484 if (opt_flags.ieeeconform) {
00485 on_off_flags.reciprical_divide = FALSE;
00486 }
00487 else {
00488 on_off_flags.reciprical_divide = !on_off_flags.eu;
00489 }
00490 }
00491 else {
00492 on_off_flags.round_integer_divide = on_off_flags.eu;
00493 }
00494
00495 if (on_off_flags.assembly_listing_file && !cmd_line_flags.binary_output) {
00496 cmd_line_flags.binary_output = TRUE;
00497 ntr_msg_queue(0, 913, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
00498 }
00499
00500 if (cmd_line_flags.co_array_fortran) {
00501 # if defined(_TASK_COMMON_EXTENSION)
00502 cmd_line_flags.taskcommon = TRUE;
00503 # endif
00504 opt_flags.task_lvl = Task_Lvl_0;
00505 }
00506
00507 # if defined(_NO_BINARY_OUTPUT)
00508 binary_output = FALSE;
00509 assembly_output = cmd_line_flags.binary_output ||
00510 cmd_line_flags.assembly_output;
00511 # else
00512 binary_output = cmd_line_flags.binary_output;
00513 assembly_output = cmd_line_flags.assembly_output;
00514 # endif
00515
00516
00517
00518
00519
00520
00521
00522
00523
00524 set_prog_file_names (argv);
00525
00526 if (optind < (argc-1)) {
00527 ntr_msg_queue(0, 79, Log_Error, 0, (char *) NULL, 0, NO_ARG);
00528 }
00529 }
00530
00531 if (cmd_line_flags.mod_out_path && !on_off_flags.module_to_mod) {
00532
00533
00534
00535 ntr_msg_queue(0, 1658, Log_Error, 0, (char *) NULL, 0, NO_ARG);
00536 }
00537
00538 PRINT_CMD_LINE_TBLS;
00539
00540 if (dump_flags.show_cmd_line) {
00541 printf("\n");
00542 for (i = 0; i < save_argc; i++) {
00543 printf("%s ", argv[i]);
00544 }
00545 printf("\n\n");
00546 }
00547
00548 issue_deferred_msgs();
00549
00550 TRACE (Func_Exit, "process_cmd_line", NULL);
00551
00552 return 0;
00553
00554 }
00555
00556
00557
00558
00559
00560
00561
00562
00563
00564
00565
00566
00567
00568
00569
00570
00571
00572
00573
00574 static void validate_G_option (void)
00575 {
00576
00577
00578 int correct_scalar_lvl;
00579 int correct_vector_lvl;
00580 int correct_task_lvl;
00581 int debug_lvl;
00582
00583
00584 TRACE (Func_Entry, "validate_G_option", NULL);
00585
00586 if (!cmd_line_flags.binary_output) {
00587
00588 # if !defined(_NO_BINARY_OUTPUT)
00589
00590
00591
00592 ntr_msg_queue(0, 82, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
00593 cmd_line_flags.assembly_output = FALSE;
00594 cmd_line_flags.binary_output = TRUE;
00595 # endif
00596
00597 }
00598
00599 switch (cmd_line_flags.debug_lvl) {
00600 case Debug_Lvl_0:
00601
00602 if (set_scalar_option && opt_flags.scalar_lvl > Scalar_Lvl_0) {
00603 ntr_msg_queue(0, 1536, Log_Warning, 0,
00604 scalar_lvl_str[Scalar_Lvl_0],
00605 Debug_Lvl_0, STR_ARG_ARG);
00606 }
00607
00608 if (set_vector_option && opt_flags.vector_lvl > Vector_Lvl_0) {
00609 ntr_msg_queue(0, 1536, Log_Warning, 0,
00610 vector_lvl_str[Vector_Lvl_0],
00611 Debug_Lvl_0, STR_ARG_ARG);
00612 }
00613
00614 if (set_stream_option && opt_flags.stream_lvl > Stream_Lvl_0) {
00615 ntr_msg_queue(0, 1536, Log_Warning, 0,
00616 stream_lvl_str[Stream_Lvl_0],
00617 Debug_Lvl_0, STR_ARG_ARG);
00618 }
00619
00620 if (set_task_option && opt_flags.task_lvl > Task_Lvl_0) {
00621 ntr_msg_queue(0, 1536, Log_Warning, 0,
00622 task_lvl_str[Task_Lvl_0],
00623 Debug_Lvl_0, STR_ARG_ARG);
00624 }
00625
00626 if (set_support_lvl_option && opt_flags.support_lvl > 0) {
00627 ntr_msg_queue(0, 1536, Log_Warning, 0,
00628 "-O0", Debug_Lvl_0, STR_ARG_ARG);
00629 }
00630
00631 if (opt_flags.inline_lvl > Inline_Lvl_0 ||
00632 set_inlinefrom_option) {
00633 ntr_msg_queue(0, 1199, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
00634 }
00635
00636 cmd_line_flags.do_UDB_checks = opt_flags.scalar_lvl > Scalar_Lvl_0;
00637 opt_flags.scalar_lvl = Scalar_Lvl_0;
00638 opt_flags.stream_lvl = Stream_Lvl_0;
00639 opt_flags.vector_lvl = Vector_Lvl_0;
00640 opt_flags.task_lvl = Task_Lvl_0;
00641 opt_flags.inline_lvl = Inline_Lvl_0;
00642 opt_flags.support_lvl = 0;
00643
00644 if (set_aggress_option) {
00645 ntr_msg_queue(0, 1069, Log_Warning, 0,
00646 "aggress", Debug_Lvl_0, STR_ARG_ARG);
00647 }
00648
00649 if (set_bottom_load_option) {
00650 ntr_msg_queue(0, 1069, Log_Warning, 0,
00651 "bl", Debug_Lvl_0, STR_ARG_ARG);
00652 }
00653
00654 if (set_loop_align_option) {
00655 ntr_msg_queue(0, 1069, Log_Warning, 0,
00656 "loopalign", Debug_Lvl_0, STR_ARG_ARG);
00657 }
00658
00659 if (set_pattern_option) {
00660 ntr_msg_queue(0, 1069, Log_Warning, 0,
00661 "pattern", Debug_Lvl_0, STR_ARG_ARG);
00662 }
00663
00664 if (set_pipeline_option) {
00665 ntr_msg_queue(0, 1069, Log_Warning, 0,
00666 "pipeline", Debug_Lvl_0, STR_ARG_ARG);
00667 }
00668
00669 if (set_recurrence_option) {
00670 ntr_msg_queue(0, 1069, Log_Warning, 0,
00671 "recurrence", Debug_Lvl_0, STR_ARG_ARG);
00672 }
00673
00674 if (set_vsearch_option) {
00675 ntr_msg_queue(0, 1069, Log_Warning, 0,
00676 "vsearch", Debug_Lvl_0, STR_ARG_ARG);
00677 }
00678
00679 if (set_zeroinc_option) {
00680 ntr_msg_queue(0, 1069, Log_Warning, 0,
00681 "zeroinc", Debug_Lvl_0, STR_ARG_ARG);
00682 }
00683
00684 opt_flags.aggress = FALSE;
00685 opt_flags.bottom_load = FALSE;
00686 opt_flags.loopalign = FALSE;
00687 opt_flags.recurrence = FALSE;
00688 opt_flags.pattern = FALSE;
00689 opt_flags.pipeline_lvl = 0;
00690 opt_flags.vsearch = FALSE;
00691 opt_flags.zeroinc = FALSE;
00692 set_debug_option = TRUE;
00693 break;
00694
00695
00696 case Debug_Lvl_1:
00697
00698 debug_lvl = Debug_Lvl_1;
00699 set_debug_option = TRUE;
00700
00701 if (opt_flags.scalar_lvl > Scalar_Lvl_2) {
00702
00703 if (set_scalar_option) {
00704 ntr_msg_queue(0, 1536, Log_Warning, 0,
00705 scalar_lvl_str[Scalar_Lvl_2],
00706 Debug_Lvl_1, STR_ARG_ARG);
00707 }
00708 opt_flags.scalar_lvl = Scalar_Lvl_2;
00709 }
00710
00711 if (opt_flags.inline_lvl > Inline_Lvl_0 ||
00712 set_inlinefrom_option) {
00713 opt_flags.inline_lvl = Inline_Lvl_0;
00714 ntr_msg_queue(0, 1199, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
00715 }
00716
00717 # if defined(_ACCEPT_STREAM)
00718
00719 if (opt_flags.stream_lvl > Stream_Lvl_1) {
00720
00721 if (set_stream_option) {
00722 ntr_msg_queue(0, 1536, Log_Warning, 0,
00723 stream_lvl_str[Stream_Lvl_1],
00724 Debug_Lvl_1, STR_ARG_ARG);
00725 }
00726
00727 opt_flags.stream_lvl = Stream_Lvl_1;
00728 }
00729 # endif
00730
00731
00732 # if defined(_ACCEPT_VECTOR)
00733
00734 if (opt_flags.vector_lvl > Vector_Lvl_1) {
00735
00736 if (set_vector_option) {
00737 ntr_msg_queue(0, 1536, Log_Warning, 0,
00738 vector_lvl_str[Vector_Lvl_1],
00739 Debug_Lvl_1, STR_ARG_ARG);
00740 }
00741
00742 opt_flags.vector_lvl = Vector_Lvl_1;
00743 }
00744 # endif
00745
00746 if (set_support_lvl_option && opt_flags.support_lvl > 1) {
00747 ntr_msg_queue(0, 1536, Log_Warning, 0,
00748 "-O1", Debug_Lvl_1, STR_ARG_ARG);
00749 opt_flags.support_lvl = 1;
00750 }
00751
00752 break;
00753
00754
00755 case Debug_Lvl_2:
00756
00757 set_debug_option = TRUE;
00758 correct_vector_lvl = Vector_Lvl_3;
00759 correct_task_lvl = Task_Lvl_3;
00760 correct_scalar_lvl = Scalar_Lvl_3;
00761 debug_lvl = Debug_Lvl_2;
00762 break;
00763
00764 case Debug_Lvl_3:
00765
00766
00767
00768 correct_vector_lvl = Vector_Lvl_3;
00769 correct_task_lvl = Task_Lvl_3;
00770 correct_scalar_lvl = Scalar_Lvl_3;
00771 debug_lvl = Debug_Lvl_3;
00772 break;
00773 }
00774
00775 TRACE (Func_Exit, "validate_G_option", NULL);
00776
00777 return;
00778
00779 }
00780
00781
00782
00783
00784
00785
00786
00787
00788
00789
00790
00791
00792
00793
00794
00795
00796
00797 static void validate_R_option( void )
00798
00799 {
00800
00801
00802 TRACE (Func_Entry, "validate_R_option", NULL);
00803
00804 if (cmd_line_flags.runtime_arg_count_only &&
00805 ! cmd_line_flags.runtime_argument &&
00806 ! cmd_line_flags.runtime_arg_call &&
00807 ! cmd_line_flags.runtime_arg_entry) {
00808
00809 cmd_line_flags.runtime_argument = TRUE;
00810 }
00811
00812 TRACE (Func_Exit, "validate_R_option", NULL);
00813
00814 return;
00815
00816 }
00817
00818
00819
00820
00821
00822
00823
00824
00825
00826
00827
00828
00829
00830
00831
00832
00833
00834
00835
00836
00837 static void init_cmd_line (void)
00838
00839 {
00840 int idx;
00841 char *u_option;
00842
00843 TRACE (Func_Entry, "init_cmd_line", NULL);
00844
00845 # if defined(_ACCEPT_STREAM)
00846 # if defined(_TARGET_SV2)
00847 accept_stream = TRUE;
00848 # else
00849 accept_stream = target_sv1;
00850 # endif
00851 # endif
00852
00853 set_support_lvl_option = FALSE;
00854
00855
00856 cif_flags = 0;
00857 cif_C_opts = 0;
00858
00859
00860
00861 cmd_line_flags.dalign = (cft90_dash_a_dalign_option == 1);
00862 cmd_line_flags.align32 = FALSE;
00863 cmd_line_flags.align64 = FALSE;
00864
00865 cmd_line_flags.taskcommon = FALSE;
00866 cmd_line_flags.static_threadprivate = FALSE;
00867 cmd_line_flags.solaris_profile = FALSE;
00868
00869 cmd_line_flags.binary_output = TRUE;
00870 cmd_line_flags.assembly_output = FALSE;
00871
00872 cmd_line_flags.runtime_argument = FALSE;
00873 cmd_line_flags.runtime_arg_call = FALSE;
00874 cmd_line_flags.runtime_arg_entry = FALSE;
00875 cmd_line_flags.runtime_arg_count_only= FALSE;
00876 cmd_line_flags.runtime_bounds = FALSE;
00877 cmd_line_flags.runtime_conformance = FALSE;
00878 cmd_line_flags.runtime_intrinsics = FALSE;
00879 cmd_line_flags.runtime_substring = FALSE;
00880 cmd_line_flags.runtime_ptr_chk = FALSE;
00881 cmd_line_flags.s_float64 = FALSE;
00882 cmd_line_flags.s_default32 = FALSE;
00883 cmd_line_flags.s_default64 = FALSE;
00884 cmd_line_flags.s_cf77types = FALSE;
00885 cmd_line_flags.s_integer8 = FALSE;
00886 cmd_line_flags.s_logical8 = FALSE;
00887 cmd_line_flags.s_real8 = FALSE;
00888 cmd_line_flags.s_complex8 = FALSE;
00889 cmd_line_flags.s_doubleprecision16 = FALSE;
00890 cmd_line_flags.s_doublecomplex16 = FALSE;
00891
00892 # if defined(_TARGET_SV2) || \
00893 ((defined(_HOST_OS_IRIX) || defined(_HOST_OS_LINUX)) && defined(_TARGET_OS_UNICOS))
00894 cmd_line_flags.s_pointer8 = TRUE;
00895 # else
00896 cmd_line_flags.s_pointer8 = FALSE;
00897 # endif
00898 cmd_line_flags.src_form = Fixed_Form;
00899 cmd_line_flags.disregard_all_mpp_cdirs = FALSE;
00900 cmd_line_flags.disregard_all_directives = FALSE;
00901 cmd_line_flags.disregard_all_dirs = FALSE;
00902 cmd_line_flags.disregard_all_mics = FALSE;
00903 cmd_line_flags.disregard_all_mips = FALSE;
00904 cmd_line_flags.disregard_all_omps = FALSE;
00905 cmd_line_flags.disregard_conditional_omp = FALSE;
00906
00907 cmd_line_flags.disregard_all_openads = FALSE;
00908 cmd_line_flags.msg_lvl_suppressed = (msg_lvl_type) cft90_dash_m_option;
00909 cmd_line_flags.truncate_bits = 0;
00910 cmd_line_flags.implicit_use_idx = NULL_IDX;
00911 cmd_line_flags.debug_lvl = (debug_lvl_type)
00912 cft90_dash_G_debug_option;
00913
00914 cmd_line_flags.mod_out_path = FALSE;
00915 cmd_line_flags.dwarf_debug = TRUE;
00916 cmd_line_flags.num_msgs_suppressed = 0;
00917 cmd_line_flags.line_size_80 = (cft90_dash_N_option == 80);
00918 cmd_line_flags.line_size_132 = (cft90_dash_N_option == 132);
00919 cmd_line_flags.verify_option = FALSE;
00920 cmd_line_flags.malleable = FALSE;
00921 cmd_line_flags.MPP_num_pes = cft90_dash_X_option;
00922 cmd_line_flags.integer_32 = FALSE;
00923 cmd_line_flags.co_array_fortran = FALSE;
00924 cmd_line_flags.pp_macro_expansion = FALSE;
00925
00926
00927
00928 on_off_flags.abort_if_any_errors = (cft90_dash_e_a_option == 1);
00929
00930
00931
00932
00933
00934 on_off_flags.pad_char_literals = FALSE;
00935 on_off_flags.ieee = TRUE;
00936 on_off_flags.flowtrace_option = FALSE;
00937 on_off_flags.assembly_listing_file = FALSE;
00938
00939 # if defined(_INTEGER_1_AND_2) && !defined(_ACCEPT_CMD_ed_h)
00940 on_off_flags.integer_1_and_2 = TRUE;
00941 # else
00942 on_off_flags.integer_1_and_2 = FALSE;
00943 # endif
00944
00945 on_off_flags.indef_init = (cft90_dash_e_i_option == 1);
00946 on_off_flags.exec_doloops_once = FALSE;
00947 on_off_flags.module_to_mod = (cft90_dash_e_m_option == 1);
00948 on_off_flags.issue_ansi_messages = (cft90_dash_e_n_option == 1);
00949 on_off_flags.enable_double_precision = (cft90_dash_e_p_option == 1);
00950 on_off_flags.abort_on_100_errors = TRUE;
00951 on_off_flags.round_mult_operations = (cft90_dash_e_r_option == 1);
00952 on_off_flags.alloc_autos_on_stack = (cft90_dash_e_t_option == 1);
00953
00954
00955
00956
00957 on_off_flags.eu = (cft90_dash_e_u_option == 1);
00958 on_off_flags.reciprical_divide = FALSE;
00959 on_off_flags.round_integer_divide = FALSE;
00960 on_off_flags.recognize_minus_zero = FALSE;
00961 on_off_flags.zero_init = FALSE;
00962 on_off_flags.save_all_vars = (cft90_dash_e_v_option == 1);
00963 on_off_flags.MPP_apprentice = FALSE;
00964 on_off_flags.shared_to_private_coer = FALSE;
00965 on_off_flags.all_debug = FALSE;
00966 on_off_flags.top_test_shortloops = FALSE;
00967 on_off_flags.remove_trailing_uscore = FALSE;
00968 on_off_flags.allow_leading_uscore = FALSE;
00969 on_off_flags.output_pound_lines = TRUE;
00970 on_off_flags.preprocess_only = FALSE;
00971 on_off_flags.preprocess = FALSE;
00972 on_off_flags.save_dot_i = FALSE;
00973 on_off_flags.recursive = FALSE;
00974 on_off_flags.atexpert = FALSE;
00975 on_off_flags.upper_case_names = FALSE;
00976 on_off_flags.d_lines = FALSE;
00977
00978
00979
00980
00981
00982
00983
00984 opt_flags.aggress = (cft90_dash_O_aggress_option == 1);
00985 opt_flags.bottom_load = (cft90_dash_O_bl_option == 1);
00986 opt_flags.set_fastint_option = FALSE;
00987 opt_flags.set_nofastint_option = FALSE;
00988 opt_flags.set_allfastint_option = FALSE;
00989 opt_flags.ieeeconform = (cft90_dash_O_ieeeconform_option==1);
00990 opt_flags.inline_lvl = Inline_Lvl_0;
00991 opt_flags.extent_assert = FALSE;
00992 opt_flags.short_circuit_lvl = Short_Circuit_Present;
00993 opt_flags.jump = (cft90_dash_O_jump_option == 1);
00994 opt_flags.loopalign = (cft90_dash_O_loopalign_option == 1);
00995 opt_flags.modinline = FALSE;
00996 opt_flags.msgs = FALSE;
00997 opt_flags.neg_msgs = FALSE;
00998 opt_flags.nointerchange = FALSE;
00999 opt_flags.opt_info = FALSE;
01000 opt_flags.over_index = (cft90_dash_O_overindex_option == 1);
01001 opt_flags.pattern = (cft90_dash_O_pattern_option == 1);
01002 opt_flags.pipeline_lvl = 0;
01003 opt_flags.recurrence = (cft90_dash_O_recurrence_option == 1);
01004 opt_flags.taskinner = (cft90_dash_O_taskinner_option == 1);
01005 opt_flags.threshold = (cft90_dash_O_threshold_option == 1);
01006 opt_flags.vsearch = (cft90_dash_O_vsearch_option == 1);
01007 opt_flags.zeroinc = (cft90_dash_O_zeroinc_option == 1);
01008 opt_flags.support_lvl = cft90_dash_O_support_option;
01009 opt_flags.scalar_lvl = cft90_dash_O_scalar_option;
01010 opt_flags.split_lvl = cft90_dash_O_split_option;
01011 opt_flags.vector_lvl = cft90_dash_O_vector_option;
01012 opt_flags.task_lvl = cft90_dash_O_task_option;
01013 opt_flags.unroll_lvl = cft90_dash_O_unroll_option;
01014 opt_flags.reshape_idx = NULL_IDX;
01015 opt_flags.reshape = FALSE;
01016 opt_flags.reshape_all_arrays = FALSE;
01017 opt_flags.matmul_inline = FALSE;
01018 opt_flags.mv_matmul_inline = FALSE;
01019
01020
01021
01022 for (idx = 0; idx < (Tok_Dir_End-Tok_Dir_Start); idx++) {
01023 disregard_directive[idx] = FALSE;
01024 }
01025
01026 for (idx = 0; idx < (Tok_Mic_End-Tok_Mic_Start); idx++) {
01027 disregard_mics[idx] = FALSE;
01028 }
01029
01030 for (idx = 0; idx < (Tok_SGI_Dir_End-Tok_SGI_Dir_Start); idx++) {
01031 disregard_mips[idx] = FALSE;
01032 }
01033
01034 for (idx = 0; idx < (Tok_Open_Mp_Dir_End-Tok_Open_Mp_Dir_Start); idx++) {
01035 disregard_open_mp[idx] = FALSE;
01036 }
01037
01038 for (idx = 0; idx < (Tok_OpenAD_Dir_End-Tok_OpenAD_Dir_Start); idx++) {
01039
01040 disregard_openad[idx] = FALSE;
01041 }
01042
01043
01044 dump_flags.pvp_test = 0;
01045 dump_flags.blk_stk = FALSE;
01046 dump_flags.bd_tbl = FALSE;
01047 dump_flags.cmd_line_tbls = FALSE;
01048 dump_flags.cn_tbl = FALSE;
01049 dump_flags.fp_tbl = FALSE;
01050 dump_flags.ftrace_info = FALSE;
01051 dump_flags.gl_tbl = FALSE;
01052 dump_flags.intrin_tbl = FALSE;
01053 dump_flags.ir1_tbl = FALSE;
01054 dump_flags.ir2_tbl = FALSE;
01055 dump_flags.ir3_tbl = FALSE;
01056 dump_flags.ir4_tbl = FALSE;
01057 dump_flags.mem_report = FALSE;
01058 dump_flags.mod_version = FALSE;
01059 dump_flags.mtrace_info = FALSE;
01060 dump_flags.name_tbls = FALSE;
01061 dump_flags.pdgcs = FALSE;
01062 dump_flags.pdt_dump = FALSE;
01063 dump_flags.sb_tbl = FALSE;
01064 dump_flags.scp_tbl = FALSE;
01065 dump_flags.src_dmp = FALSE;
01066 dump_flags.std_err = FALSE;
01067 dump_flags.stmt_dmp = FALSE;
01068 dump_flags.sytb = FALSE;
01069 dump_flags.typ_tbl = FALSE;
01070 dump_flags.defines = FALSE;
01071 dump_flags.constant_bits = FALSE;
01072 dump_flags.abort_on_ansi = FALSE;
01073 dump_flags.no_dimension_padding = FALSE;
01074 dump_flags.no_module_output = FALSE;
01075 dump_flags.f_minus_minus = FALSE;
01076 dump_flags.fmm1 = FALSE;
01077 dump_flags.fmm2 = FALSE;
01078 dump_flags.show_cmd_line = FALSE;
01079 dump_flags.mp = FALSE;
01080 dump_flags.open_mp = FALSE;
01081 dump_flags.dsm = FALSE;
01082 dump_flags.cray_compatible = FALSE;
01083 dump_flags.pack_half_word = FALSE;
01084
01085
01086
01087 ccg_dump_flags = 0;
01088
01089
01090
01091
01092 for (idx = 0; idx < MAX_MSG_SIZE; idx++) {
01093 message_suppress_tbl[idx] = 0L;
01094 message_error_tbl[idx] = 0L;
01095 message_warning_tbl[idx] = 0L;
01096 }
01097
01098 u_option = getenv("FE_DASH_U_OPTION");
01099
01100 if (u_option != NULL) {
01101 process_u_option(u_option);
01102 }
01103
01104 TRACE (Func_Exit, "init_cmd_line", NULL);
01105
01106 return;
01107
01108 }
01109
01110
01111
01112
01113
01114
01115
01116
01117
01118
01119
01120
01121
01122
01123
01124
01125
01126
01127
01128
01129
01130
01131
01132
01133
01134
01135
01136
01137
01138
01139
01140
01141
01142
01143
01144
01145
01146
01147
01148
01149
01150 static void process_C_option (char *optargs,
01151 char *argv[])
01152
01153 {
01154 int ch;
01155 char err_str[2];
01156 long orig_cmd_len;
01157
01158 extern int optind;
01159
01160
01161 TRACE (Func_Entry, "process_C_option", NULL);
01162
01163 while (ch = *optargs++) {
01164
01165 switch (ch) {
01166 case 'a':
01167 cif_flags = cif_flags | ALL_RECS |
01168 XREF_RECS | MISC_RECS |
01169 MESSAGE_RECS | INFO_RECS |
01170 BASIC_RECS | COMPILER_RECS;
01171 cif_C_opts = cif_C_opts | ALL_RECS;
01172 break;
01173
01174 case 'c':
01175 cif_flags = cif_flags | COMPILER_RECS | BASIC_RECS;
01176 cif_C_opts = cif_C_opts | COMPILER_RECS;
01177 break;
01178
01179 case 'f':
01180 cif_flags = cif_flags | BASIC_RECS;
01181 cif_C_opts = cif_C_opts | BASIC_RECS;
01182 break;
01183
01184 case 'i':
01185 cif_flags = cif_flags | INFO_RECS | BASIC_RECS;
01186 cif_C_opts = cif_C_opts | INFO_RECS;
01187 break;
01188
01189 case 'm':
01190 cif_flags = cif_flags | MESSAGE_RECS | BASIC_RECS;
01191 cif_C_opts = cif_C_opts | MESSAGE_RECS;
01192 break;
01193
01194 case 'o':
01195 cif_flags = cif_flags | MISC_RECS | INFO_RECS | BASIC_RECS;
01196 cif_C_opts = cif_C_opts | MISC_RECS;
01197 break;
01198
01199 case 's':
01200 cif_flags = cif_flags | OUTPUT_TO_STDOUT;
01201 cif_C_opts = cif_C_opts | OUTPUT_TO_STDOUT;
01202 break;
01203
01204 case 'x':
01205 cif_flags = cif_flags | XREF_RECS | INFO_RECS | BASIC_RECS;
01206 cif_C_opts = cif_C_opts | XREF_RECS;
01207 break;
01208
01209 case 'Y':
01210
01211
01212
01213
01214
01215
01216
01217 orig_cmd_len = (long) strlen(argv[optind]);
01218 ++orig_cmd_len;
01219 MEM_ALLOC(orig_cmd_line, char, orig_cmd_len);
01220 strcpy(orig_cmd_line, argv[optind]);
01221 ++optind;
01222 break;
01223
01224 case 'Z':
01225
01226
01227
01228
01229
01230
01231 strcpy(cif_name, optargs);
01232
01233
01234
01235
01236
01237 optargs = optargs + strlen(optargs);
01238 break;
01239
01240 default:
01241 err_str[0] = ch;
01242 err_str[1] = EOS;
01243
01244
01245
01246 ntr_msg_queue(0, 917, Log_Error, 0, err_str, 0, STR_ARG);
01247 break;
01248
01249 }
01250
01251 }
01252
01253 if (cif_flags != 0) {
01254 cif_C_opts = cif_C_opts | CMD_PROVIDED_CIF;
01255 }
01256
01257
01258
01259
01260 if (cif_flags == OUTPUT_TO_STDOUT) {
01261 cif_flags = 0;
01262 cif_C_opts = 0;
01263 }
01264
01265 TRACE (Func_Exit, "process_C_option", NULL);
01266
01267 return;
01268
01269 }
01270
01271
01272
01273
01274
01275
01276
01277
01278
01279
01280
01281
01282
01283
01284
01285
01286
01287
01288
01289 static void process_d_option (char *optargs)
01290
01291 {
01292 int ch;
01293 char err_str[2];
01294
01295
01296 TRACE (Func_Entry, "process_d_option", NULL);
01297
01298 while (ch = *optargs++) {
01299 switch (ch) {
01300 case 'a':
01301 on_off_flags.abort_if_any_errors = FALSE;
01302 break;
01303
01304 # if defined(GENERATE_WHIRL)
01305 case 'c':
01306 on_off_flags.pad_char_literals = FALSE;
01307 break;
01308 # endif
01309
01310 # ifdef _D_LINES_SUPPORTED
01311 case 'd':
01312 on_off_flags.d_lines = FALSE;
01313 break;
01314 # endif
01315
01316 # if 0
01317
01318
01319
01320
01321
01322 case 'e':
01323 on_off_flags.ieee = FALSE;
01324 break;
01325
01326 # endif
01327
01328 case 'f':
01329
01330 # if defined(_ACCEPT_FLOW)
01331 on_off_flags.flowtrace_option = FALSE;
01332 # else
01333 ntr_msg_queue(0, 744, Log_Warning, 0, "f", 'd', ARG_STR_ARG);
01334 # endif
01335 break;
01336
01337 case 'g':
01338
01339 # if defined(_ACCEPT_CMD_ed_g)
01340 on_off_flags.assembly_listing_file = FALSE;
01341 # else
01342 ntr_msg_queue(0, 744, Log_Warning, 0, "g", 'd', ARG_STR_ARG);
01343 # endif
01344 break;
01345
01346 case 'h':
01347
01348 # if defined(_ACCEPT_CMD_ed_h)
01349 on_off_flags.integer_1_and_2 = FALSE;
01350 # else
01351 ntr_msg_queue(0, 744, Log_Warning, 0, "h", 'd', ARG_STR_ARG);
01352 # endif
01353 break;
01354
01355 case 'i':
01356
01357 # if defined(_ACCEPT_CMD_ed_i)
01358 ntr_msg_queue(0, 744, Log_Warning, 0, "i", 'd', ARG_STR_ARG);
01359 # else
01360 on_off_flags.indef_init = FALSE;
01361 # endif
01362 break;
01363
01364 case 'j':
01365
01366 # if defined(_ACCEPT_CMD_ed_j)
01367 on_off_flags.exec_doloops_once = FALSE;
01368 # else
01369 ntr_msg_queue(0, 744, Log_Warning, 0, "j", 'd', ARG_STR_ARG);
01370 # endif
01371 break;
01372
01373 case 'k': on_off_flags.output_pound_lines = FALSE;
01374 break;
01375
01376 case 'm':
01377
01378
01379
01380 # if defined(_MODULE_TO_DOT_o) || defined(_MODULE_TO_DOT_M)
01381 on_off_flags.module_to_mod = FALSE;
01382 # else
01383 PRINTMSG (0, 744, Log_Warning, 0, 'd', "m");
01384 # endif
01385 break;
01386
01387 case 'n':
01388 on_off_flags.issue_ansi_messages = FALSE;
01389 break;
01390
01391 case 'p':
01392 on_off_flags.enable_double_precision = FALSE;
01393 break;
01394
01395 case 'q':
01396 on_off_flags.abort_on_100_errors = FALSE;
01397 break;
01398
01399 case 'r':
01400
01401 # if defined(_ACCEPT_CMD_ed_r)
01402
01403 if (set_trunc_option) {
01404 set_round_option = FALSE;
01405
01406
01407
01408 ntr_msg_queue(0, 75, Log_Warning, 0, "-dr", 0, STR_ARG);
01409 }
01410
01411 cmd_line_flags.truncate_bits = 0;
01412 on_off_flags.round_mult_operations = FALSE;
01413 set_round_option = TRUE;
01414 # else
01415 ntr_msg_queue(0, 744, Log_Warning, 0, "r", 'd', ARG_STR_ARG);
01416 # endif
01417 break;
01418
01419 case 't':
01420 on_off_flags.alloc_autos_on_stack = FALSE;
01421 break;
01422
01423 case 'u':
01424 set_eu_option = TRUE;
01425 on_off_flags.eu = FALSE;
01426 break;
01427
01428 case 'v':
01429 on_off_flags.save_all_vars = FALSE;
01430 break;
01431
01432 case 'z':
01433
01434 # if defined(_ACCEPT_CMD_ed_z)
01435 on_off_flags.recognize_minus_zero = FALSE;
01436 # else
01437 ntr_msg_queue(0, 744, Log_Warning, 0, "z", 'd', ARG_STR_ARG);
01438 # endif
01439 break;
01440
01441 case '0':
01442 # if defined(_ACCEPT_CMD_ed_0)
01443 on_off_flags.zero_init = FALSE;
01444 # else
01445 ntr_msg_queue(0, 744, Log_Warning, 0, "0", 'd', ARG_STR_ARG);
01446 # endif
01447 break;
01448
01449 case 'A':
01450
01451 # if defined(_ACCEPT_CMD_ed_A)
01452 on_off_flags.MPP_apprentice = FALSE;
01453 # else
01454 ntr_msg_queue(0, 744, Log_Warning, 0, "A", 'd', ARG_STR_ARG);
01455 # endif
01456 break;
01457
01458 case 'B':
01459 cmd_line_flags.binary_output = FALSE;
01460 break;
01461
01462 case 'C':
01463
01464 # if defined(_ACCEPT_CMD_ed_C)
01465 on_off_flags.shared_to_private_coer = FALSE;
01466 # else
01467 ntr_msg_queue(0, 744, Log_Warning, 0, "C", 'd', ARG_STR_ARG);
01468 # endif
01469 break;
01470
01471 case 'D':
01472 # if defined(_ACCEPT_CMD_ed_i)
01473 on_off_flags.all_debug = FALSE;
01474 # else
01475 ntr_msg_queue(0, 744, Log_Warning, 0, "D", 'd', ARG_STR_ARG);
01476 # endif
01477 break;
01478
01479 case 'I':
01480 on_off_flags.implicit_none = FALSE;
01481 break;
01482
01483 case 'L':
01484 on_off_flags.top_test_shortloops = FALSE;
01485 break;
01486
01487 case 'N':
01488 on_off_flags.remove_trailing_uscore = FALSE;
01489 break;
01490
01491 case 'Q':
01492 on_off_flags.allow_leading_uscore = FALSE;
01493 break;
01494
01495 case 'R':
01496 on_off_flags.recursive = FALSE;
01497 break;
01498
01499 case 'S':
01500 cmd_line_flags.assembly_output = FALSE;
01501 break;
01502
01503 case 'T':
01504 # ifdef _FRONTEND_CONDITIONAL_COMP
01505 no_preprocessing = TRUE;
01506 on_off_flags.preprocess = FALSE;
01507 on_off_flags.preprocess_only = FALSE;
01508 on_off_flags.save_dot_i = FALSE;
01509 # endif
01510 break;
01511
01512 case 'U':
01513 # if defined(_ACCEPT_CMD_ed_U)
01514 on_off_flags.upper_case_names = FALSE;
01515 # else
01516 ntr_msg_queue(0, 744, Log_Warning, 0, "U", 'd', ARG_STR_ARG);
01517 # endif
01518 break;
01519
01520 case 'X':
01521
01522 # if defined(_ACCEPT_CMD_ed_X)
01523 on_off_flags.atexpert = FALSE;
01524 # else
01525 ntr_msg_queue(0, 744, Log_Warning, 0, "X", 'd', ARG_STR_ARG);
01526 # endif
01527 break;
01528
01529 default:
01530 err_str[0] = ch;
01531 err_str[1] = EOS;
01532
01533
01534
01535 ntr_msg_queue(0, 78, Log_Error, 0, err_str, 'd', ARG_STR_ARG);
01536 break;
01537
01538 }
01539 }
01540
01541 TRACE (Func_Exit, "process_d_option", NULL);
01542
01543 return;
01544
01545 }
01546
01547
01548
01549
01550
01551
01552
01553
01554
01555
01556
01557
01558
01559
01560
01561
01562
01563
01564 static void process_e_option (char *optargs)
01565
01566 {
01567 int ch;
01568 char err_str[2];
01569
01570
01571 TRACE (Func_Entry, "process_e_option", NULL);
01572
01573 while (ch = *optargs++) {
01574 switch (ch) {
01575 case 'a':
01576 on_off_flags.abort_if_any_errors = TRUE;
01577 break;
01578
01579 # if defined(GENERATE_WHIRL)
01580 case 'c':
01581 on_off_flags.pad_char_literals = TRUE;
01582 break;
01583 # endif
01584
01585 # ifdef _D_LINES_SUPPORTED
01586 case 'd':
01587 on_off_flags.d_lines = TRUE;
01588 break;
01589 # endif
01590
01591
01592 # if 0
01593
01594
01595
01596
01597 case 'e':
01598 on_off_flags.ieee = TRUE;
01599 break;
01600
01601 # endif
01602
01603 case 'f':
01604
01605 # if defined(_ACCEPT_FLOW)
01606 on_off_flags.flowtrace_option = TRUE;
01607 # else
01608 ntr_msg_queue(0, 744, Log_Warning, 0, "f", 'e', ARG_STR_ARG);
01609 # endif
01610 break;
01611
01612 case 'g':
01613
01614 # if defined(_ACCEPT_CMD_ed_g)
01615 on_off_flags.assembly_listing_file = TRUE;
01616
01617
01618
01619 if (cmd_line_flags.assembly_output) {
01620 ntr_msg_queue(0, 388, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
01621 cmd_line_flags.assembly_output = FALSE;
01622 cmd_line_flags.binary_output = TRUE;
01623 }
01624 # else
01625 ntr_msg_queue(0, 744, Log_Warning, 0, "g", 'r', ARG_STR_ARG);
01626 # endif
01627 break;
01628
01629
01630 case 'h':
01631
01632 # if defined(_ACCEPT_CMD_ed_h)
01633 on_off_flags.integer_1_and_2 = TRUE;
01634 # else
01635 ntr_msg_queue(0, 744, Log_Warning, 0, "h", 'e', ARG_STR_ARG);
01636 # endif
01637 break;
01638
01639
01640 case 'i':
01641
01642 # if defined(_ACCEPT_CMD_ed_i)
01643 on_off_flags.indef_init = TRUE;
01644
01645 if (on_off_flags.zero_init) {
01646 on_off_flags.zero_init = FALSE;
01647 ntr_msg_queue(0, 1313, Log_Warning, 0, "ei\ne0", 0,MULT_STR_ARG);
01648 }
01649 # else
01650 ntr_msg_queue(0, 744, Log_Warning, 0, "i", 'e', ARG_STR_ARG);
01651 # endif
01652 break;
01653
01654 case 'j':
01655
01656 # if defined(_ACCEPT_CMD_ed_j)
01657 on_off_flags.exec_doloops_once = TRUE;
01658 # else
01659 ntr_msg_queue(0, 744, Log_Warning, 0, "j", 'e', ARG_STR_ARG);
01660 # endif
01661 break;
01662
01663 case 'k':
01664 on_off_flags.save_dot_i = TRUE;
01665 break;
01666
01667 case 'm':
01668 on_off_flags.module_to_mod = TRUE;
01669 break;
01670
01671 case 'n':
01672 on_off_flags.issue_ansi_messages = TRUE;
01673 break;
01674
01675 case 'p':
01676 on_off_flags.enable_double_precision = TRUE;
01677 break;
01678
01679 case 'q':
01680 on_off_flags.abort_on_100_errors = TRUE;
01681 break;
01682
01683 case 'r':
01684
01685 # if defined(_ACCEPT_CMD_ed_r)
01686
01687 if (set_trunc_option) {
01688
01689
01690
01691 ntr_msg_queue(0, 75, Log_Warning, 0, "-er", 0, STR_ARG);
01692 set_trunc_option = FALSE;
01693 }
01694
01695 on_off_flags.round_mult_operations = TRUE;
01696 cmd_line_flags.truncate_bits = 0;
01697 set_round_option = TRUE;
01698 # else
01699 ntr_msg_queue(0, 744, Log_Warning, 0, "r", 'e', ARG_STR_ARG);
01700 # endif
01701 break;
01702
01703 case 't':
01704 on_off_flags.alloc_autos_on_stack = TRUE;
01705 break;
01706
01707 case 'u':
01708 on_off_flags.eu = TRUE;
01709 set_eu_option = TRUE;
01710 break;
01711
01712 case 'v':
01713 on_off_flags.save_all_vars = TRUE;
01714 break;
01715
01716 case 'z':
01717
01718 # if defined(_ACCEPT_CMD_ed_z)
01719 on_off_flags.recognize_minus_zero = TRUE;
01720 # else
01721 ntr_msg_queue(0, 744, Log_Warning, 0, "z", 'e', ARG_STR_ARG);
01722 # endif
01723 break;
01724
01725 case '0':
01726 # if defined(_ACCEPT_CMD_ed_0)
01727 on_off_flags.zero_init = TRUE;
01728
01729 if (on_off_flags.indef_init) {
01730 on_off_flags.indef_init = FALSE;
01731 ntr_msg_queue(0, 1313, Log_Warning, 0, "e0\nei", 0,MULT_STR_ARG);
01732 }
01733
01734 # else
01735 ntr_msg_queue(0, 744, Log_Warning, 0, "0", 'e', ARG_STR_ARG);
01736 # endif
01737 break;
01738
01739 case 'A':
01740
01741 # if defined(_ACCEPT_CMD_ed_A)
01742 on_off_flags.MPP_apprentice = TRUE;
01743 # else
01744 ntr_msg_queue(0, 744, Log_Warning, 0, "A", 'e', ARG_STR_ARG);
01745 # endif
01746 break;
01747
01748 case 'B':
01749
01750
01751
01752 if (cmd_line_flags.assembly_output) {
01753 ntr_msg_queue(0, 715, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
01754 cmd_line_flags.assembly_output = FALSE;
01755 }
01756
01757 cmd_line_flags.binary_output = TRUE;
01758 break;
01759
01760 case 'C':
01761
01762 # if defined(_ACCEPT_CMD_ed_C)
01763 on_off_flags.shared_to_private_coer = TRUE;
01764 # else
01765 ntr_msg_queue(0, 744, Log_Warning, 0, "C", 'e', ARG_STR_ARG);
01766 # endif
01767 break;
01768
01769 case 'D':
01770 # if defined(_ACCEPT_CMD_ed_D)
01771 on_off_flags.all_debug = TRUE;
01772 # else
01773 ntr_msg_queue(0, 744, Log_Warning, 0, "D", 'e', ARG_STR_ARG);
01774 # endif
01775 break;
01776
01777 case 'I':
01778 on_off_flags.implicit_none = TRUE;
01779 break;
01780
01781 case 'L':
01782 on_off_flags.top_test_shortloops = TRUE;
01783 break;
01784
01785 case 'N':
01786 on_off_flags.remove_trailing_uscore = TRUE;
01787 break;
01788
01789 case 'Q':
01790 on_off_flags.allow_leading_uscore = TRUE;
01791 break;
01792
01793 case 'R':
01794 on_off_flags.recursive = TRUE;
01795 break;
01796
01797 case 'S':
01798
01799
01800
01801 if (cmd_line_flags.binary_output) {
01802
01803 cmd_line_flags.binary_output = FALSE;
01804 }
01805
01806
01807
01808 if (on_off_flags.assembly_listing_file) {
01809 ntr_msg_queue(0, 911, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
01810 on_off_flags.assembly_listing_file = FALSE;
01811 }
01812
01813 cmd_line_flags.assembly_output = TRUE;
01814 break;
01815
01816 case 'T':
01817 # ifdef _FRONTEND_CONDITIONAL_COMP
01818 no_preprocessing = FALSE;
01819 on_off_flags.preprocess = TRUE;
01820 # endif
01821 break;
01822
01823 case 'U':
01824 # if defined(_ACCEPT_CMD_ed_U)
01825 on_off_flags.upper_case_names = TRUE;
01826 # else
01827 ntr_msg_queue(0, 744, Log_Warning, 0, "U", 'e', ARG_STR_ARG);
01828 # endif
01829 break;
01830
01831 case 'X':
01832
01833 # if defined(_ACCEPT_CMD_ed_X)
01834 on_off_flags.atexpert = TRUE;
01835 # else
01836 ntr_msg_queue(0, 744, Log_Warning, 0, "X", 'e', ARG_STR_ARG);
01837 # endif
01838 break;
01839
01840 case 'Z':
01841 # ifdef _FRONTEND_CONDITIONAL_COMP
01842 no_preprocessing = FALSE;
01843 on_off_flags.preprocess_only = TRUE;
01844 on_off_flags.preprocess = TRUE;
01845 # endif
01846 break;
01847
01848 default:
01849 err_str[0] = ch;
01850 err_str[1] = EOS;
01851
01852
01853
01854 ntr_msg_queue(0, 78, Log_Error, 0, err_str, 'e', ARG_STR_ARG);
01855 break;
01856 }
01857 }
01858
01859 TRACE (Func_Exit, "process_e_option", NULL);
01860
01861 return;
01862
01863 }
01864
01865
01866
01867
01868
01869
01870
01871
01872
01873
01874
01875
01876
01877
01878
01879
01880
01881
01882 static void process_O_option (char *optargs,
01883 int argc)
01884
01885 {
01886 char *cp;
01887 boolean err;
01888 boolean first;
01889 extern int optind;
01890
01891
01892 TRACE (Func_Entry, "process_O_option", NULL);
01893
01894 if (*optargs == '-') {
01895
01896
01897
01898
01899 ntr_msg_queue(0, 1221, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
01900 --optind;
01901 return;
01902 }
01903
01904 first = TRUE;
01905
01906 while (*optargs != EOS) {
01907
01908 for (cp = optargs;
01909 *optargs != BLANK && *optargs != COMMA && *optargs != EOS;
01910 ++optargs);
01911
01912 if (*optargs != EOS) {
01913 *optargs = EOS;
01914 *optargs++;
01915 }
01916
01917 err = FALSE;
01918
01919 switch (*cp) {
01920
01921 case '0':
01922 if (EQUAL_STRS(cp, "0")) {
01923 opt_flags.support_lvl = 0;
01924 set_support_lvl_option = TRUE;
01925
01926 if (! set_scalar_option) {
01927 opt_flags.scalar_lvl = Scalar_Lvl_0;
01928 }
01929
01930 # if defined(_ACCEPT_VECTOR)
01931
01932 if (! set_vector_option) {
01933 opt_flags.vector_lvl = Vector_Lvl_0;
01934 }
01935
01936 # endif
01937
01938 # if defined(_ACCEPT_STREAM)
01939
01940 if (! set_stream_option) {
01941 opt_flags.stream_lvl = Stream_Lvl_0;
01942 }
01943
01944 # endif
01945
01946
01947 # if defined(_ACCEPT_TASK)
01948
01949 if (! set_task_option) {
01950 opt_flags.task_lvl = Task_Lvl_0;
01951 }
01952
01953 # endif
01954
01955 }
01956 else {
01957 err = TRUE;
01958 }
01959
01960 break;
01961
01962
01963 case '1':
01964 if (EQUAL_STRS(cp, "1")) {
01965 opt_flags.support_lvl = 1;
01966 set_support_lvl_option = TRUE;
01967
01968 if (! set_scalar_option) {
01969 opt_flags.scalar_lvl = Scalar_Lvl_1;
01970 }
01971
01972 # if defined(_ACCEPT_VECTOR)
01973
01974 if (! set_vector_option) {
01975 opt_flags.vector_lvl = Vector_Lvl_1;
01976 }
01977
01978 # endif
01979
01980 # if defined(_ACCEPT_STREAM)
01981
01982 if (! set_stream_option) {
01983
01984 # if defined(_TARGET_SV2)
01985 opt_flags.stream_lvl = Stream_Lvl_1;
01986 # else
01987 opt_flags.stream_lvl = Stream_Lvl_0;
01988 # endif
01989 }
01990
01991 # endif
01992
01993 # if defined(_ACCEPT_TASK)
01994
01995 if (! set_task_option) {
01996 opt_flags.task_lvl = Task_Lvl_1;
01997 }
01998
01999 # endif
02000
02001 }
02002 else {
02003 err = TRUE;
02004 }
02005
02006 break;
02007
02008
02009 case '2':
02010 if (EQUAL_STRS(cp, "2")) {
02011 opt_flags.support_lvl = 2;
02012 set_support_lvl_option = TRUE;
02013
02014 if (! set_scalar_option) {
02015 opt_flags.scalar_lvl = Scalar_Lvl_2;
02016 }
02017
02018 # if defined(_ACCEPT_STREAM)
02019
02020 if (! set_stream_option) {
02021
02022 # if defined(_TARGET_SV2)
02023 opt_flags.stream_lvl = Stream_Lvl_2;
02024 # else
02025 opt_flags.stream_lvl = Stream_Lvl_0;
02026 # endif
02027 }
02028
02029 # endif
02030
02031 # if defined(_ACCEPT_VECTOR)
02032
02033 if (! set_vector_option) {
02034 opt_flags.vector_lvl = Vector_Lvl_2;
02035 }
02036
02037 # endif
02038
02039 # if defined(_ACCEPT_TASK)
02040
02041 if (! set_task_option) {
02042 opt_flags.task_lvl = Task_Lvl_1;
02043 }
02044
02045 # endif
02046
02047 }
02048 else {
02049 err = TRUE;
02050 }
02051
02052 break;
02053
02054
02055 case '3':
02056 if (EQUAL_STRS(cp, "3")) {
02057 opt_flags.support_lvl = 3;
02058 set_support_lvl_option = TRUE;
02059
02060 if (! set_scalar_option) {
02061 opt_flags.scalar_lvl = Scalar_Lvl_2;
02062 }
02063
02064 # if defined(_ACCEPT_VECTOR)
02065
02066 if (! set_vector_option) {
02067 opt_flags.vector_lvl = Vector_Lvl_3;
02068 }
02069
02070 # endif
02071
02072 # if defined(_ACCEPT_STREAM)
02073
02074 if (! set_stream_option) {
02075
02076 # if defined(_TARGET_SV2)
02077 opt_flags.stream_lvl = Stream_Lvl_3;
02078 # else
02079 opt_flags.stream_lvl = Stream_Lvl_0;
02080 # endif
02081 }
02082
02083 # endif
02084
02085
02086 # if defined(_ACCEPT_TASK)
02087
02088 if (! set_task_option) {
02089 opt_flags.task_lvl = Task_Lvl_2;
02090 }
02091
02092 # endif
02093
02094 }
02095 else {
02096 err = TRUE;
02097 }
02098
02099 break;
02100
02101
02102 case 'a':
02103 if (EQUAL_STRS(cp, "aggress")) {
02104 opt_flags.aggress = TRUE;
02105 set_aggress_option = TRUE;
02106 }
02107 else if (EQUAL_STRS(cp, "allfastint")) {
02108
02109 # if defined(_ACCEPT_CMD_O_FASTINT)
02110 opt_flags.set_allfastint_option = TRUE;
02111
02112 if (set_i_option) {
02113 ntr_msg_queue(0, 1192, Log_Warning, 0,
02114 "-i\n-O allfastint\n-i",
02115 0, MULT_STR_ARG);
02116 }
02117 # else
02118 ntr_msg_queue(0, 744, Log_Warning, 0,
02119 "allfastint", 'O', ARG_STR_ARG);
02120 # endif
02121 }
02122 else {
02123 err = TRUE;
02124 }
02125
02126 break;
02127
02128
02129 case 'b':
02130 if (! EQUAL_STRS(cp, "bl")) {
02131 err = TRUE;
02132 }
02133 else {
02134
02135 # if defined(_ACCEPT_BL)
02136
02137 opt_flags.bottom_load = TRUE;
02138 set_bottom_load_option = TRUE;
02139
02140 # else
02141
02142 ntr_msg_queue(0, 744, Log_Warning, 0, "bl", 'O', ARG_STR_ARG);
02143
02144 # endif
02145
02146 }
02147
02148 break;
02149
02150
02151 case 'f':
02152
02153 if (EQUAL_STRS(cp, "fastint")) {
02154
02155 # if defined(_ACCEPT_CMD_O_FASTINT)
02156 opt_flags.set_fastint_option = TRUE;
02157 if (set_i_option) {
02158 ntr_msg_queue(0, 1192, Log_Warning, 0,
02159 "-i\n-O fastint\n-i",
02160 0, MULT_STR_ARG);
02161 }
02162 # else
02163 ntr_msg_queue(0, 744, Log_Warning, 0,
02164 "fastint", 'O', ARG_STR_ARG);
02165 # endif
02166 }
02167 else if (EQUAL_STRS(cp, "fusion")) {
02168
02169 # if defined(_ACCEPT_CMD_O_FUSION)
02170 opt_flags.fusion = TRUE;
02171 # else
02172 ntr_msg_queue(0, 744, Log_Warning, 0,
02173 "fusion", 'O', ARG_STR_ARG);
02174 # endif
02175 }
02176 else {
02177 err = TRUE;
02178 }
02179 break;
02180
02181
02182 case 'i':
02183
02184 if (EQUAL_STRS(cp, "ieeeconform")) {
02185
02186 if (target_ieee) {
02187 opt_flags.ieeeconform = TRUE;
02188 set_ieeeconform_option = TRUE;
02189 }
02190 else {
02191 ntr_msg_queue(0, 744, Log_Warning, 0,
02192 "ieeeconform", 'O', ARG_STR_ARG);
02193 }
02194 }
02195 else if ((strncmp (cp, "inlinefrom=", 11) == IDENTICAL)) {
02196 cp = cp+11;
02197 add_to_fp_table (cp, &inline_path_idx, 'O');
02198 set_inlinefrom_option = TRUE;
02199 }
02200 else if (EQUAL_STRS(cp, "inline0")) {
02201
02202 # if defined(_ACCEPT_INLINE)
02203
02204 opt_flags.inline_lvl = Inline_Lvl_0;
02205
02206 # else
02207
02208 ntr_msg_queue(0, 744, Log_Warning, 0,
02209 "inline0", 'O', ARG_STR_ARG);
02210
02211 # endif
02212
02213 }
02214 else if (EQUAL_STRS(cp, "inline1") ||
02215 EQUAL_STRS(cp, "inlinee1")) {
02216
02217 # if defined(_ACCEPT_INLINE)
02218
02219 if (EQUAL_STRS(cp, "inlinee1")) {
02220 opt_flags.extent_assert = TRUE;
02221 }
02222
02223 opt_flags.inline_lvl = Inline_Lvl_1;
02224
02225 # else
02226
02227 ntr_msg_queue(0, 744, Log_Warning, 0,
02228 "inline1", 'O', ARG_STR_ARG);
02229
02230 # endif
02231
02232 }
02233 else if (EQUAL_STRS(cp, "inline2") ||
02234 EQUAL_STRS(cp, "inlinee2")) {
02235
02236 # if defined(_ACCEPT_INLINE)
02237
02238 if (EQUAL_STRS(cp, "inlinee2")) {
02239 opt_flags.extent_assert = TRUE;
02240 }
02241
02242 opt_flags.inline_lvl = Inline_Lvl_2;
02243
02244 # else
02245
02246 ntr_msg_queue(0, 744, Log_Warning, 0,
02247 "inline2", 'O', ARG_STR_ARG);
02248
02249 # endif
02250
02251 }
02252 else if (EQUAL_STRS(cp, "inline3") ||
02253 EQUAL_STRS(cp, "inlinee3")) {
02254
02255 # if defined(_ACCEPT_INLINE)
02256
02257 if (EQUAL_STRS(cp, "inlinee3")) {
02258 opt_flags.extent_assert = TRUE;
02259 }
02260
02261 opt_flags.inline_lvl = Inline_Lvl_3;
02262 ntr_msg_queue(0, 1548, Log_Warning, 0,
02263 "-O inline3", 0, STR_ARG);
02264
02265 # else
02266
02267 ntr_msg_queue(0, 744, Log_Warning, 0,
02268 "inline3", 'O', ARG_STR_ARG);
02269
02270 # endif
02271 }
02272 else if (EQUAL_STRS(cp, "inline4") ||
02273 EQUAL_STRS(cp, "inlinee4")) {
02274
02275 # if defined(_ACCEPT_INLINE)
02276
02277 if (EQUAL_STRS(cp, "inlinee4")) {
02278 opt_flags.extent_assert = TRUE;
02279 }
02280
02281 opt_flags.inline_lvl = Inline_Lvl_4;
02282
02283 # else
02284
02285 ntr_msg_queue(0, 744, Log_Warning, 0,
02286 "inline4", 'O', ARG_STR_ARG);
02287
02288 # endif
02289 }
02290 else {
02291 err = TRUE;
02292 }
02293
02294 if (set_debug_option) {
02295 opt_flags.inline_lvl = Inline_Lvl_0;
02296 }
02297
02298 break;
02299
02300
02301 case 'j':
02302
02303 if (! EQUAL_STRS(cp, "jump")) {
02304 err = TRUE;
02305 }
02306 else {
02307
02308 # if defined(_ACCEPT_CMD_O_JUMP)
02309 opt_flags.jump = TRUE;
02310 # else
02311 ntr_msg_queue(0, 744, Log_Warning, 0, "jump", 'O', ARG_STR_ARG);
02312 # endif
02313
02314 }
02315
02316 break;
02317
02318
02319 case 'l':
02320
02321 if ( !EQUAL_STRS(cp, "loopalign")) {
02322 err = TRUE;
02323 }
02324 else {
02325
02326 # if defined(_ACCEPT_CMD_O_LOOPALIGN)
02327
02328 opt_flags.loopalign = TRUE;
02329 set_loop_align_option = TRUE;
02330
02331 # else
02332
02333 ntr_msg_queue(0, 744, Log_Warning, 0,
02334 "loopalign", 'O', ARG_STR_ARG);
02335
02336 # endif
02337
02338 }
02339
02340 break;
02341
02342
02343 case 'm':
02344
02345 if (EQUAL_STRS(cp, "modinline")) {
02346
02347 # if defined(_ACCEPT_INLINE)
02348 opt_flags.modinline = TRUE;
02349 # else
02350
02351 ntr_msg_queue(0, 744, Log_Warning, 0,
02352 "modinline", 'O', ARG_STR_ARG);
02353
02354 # endif
02355
02356 }
02357 else if (EQUAL_STRS(cp, "msgs")) {
02358 opt_flags.msgs = TRUE;
02359 }
02360 else if (strncmp(cp, "mark", 4) == 0) {
02361 opt_flags.mark = TRUE;
02362 cp +=4;
02363
02364 if (*cp != EOS) {
02365
02366 if (*cp != EQUAL) {
02367 err = TRUE;
02368 }
02369 else {
02370 ++cp;
02371 strcpy(opt_flags.mark_name.string, cp);
02372 }
02373 }
02374 }
02375 else if (EQUAL_STRS(cp, "matmul_inline")) {
02376
02377 # if defined(_ACCEPT_CMD_O_MATMUL_INLINE)
02378 opt_flags.matmul_inline = TRUE;
02379 # else
02380 PRINTMSG (0, 744, Log_Warning, 0, 'O', "matmul_inline");
02381 # endif
02382
02383 }
02384 else if (EQUAL_STRS(cp, "mv_matmul_inline")) {
02385
02386 # if defined(_ACCEPT_CMD_O_MATMUL_INLINE)
02387 opt_flags.mv_matmul_inline = TRUE;
02388 # else
02389 PRINTMSG (0, 744, Log_Warning, 0, 'O', "mv_matmul_inline");
02390 # endif
02391
02392 }
02393 else {
02394 err = TRUE;
02395 }
02396
02397 break;
02398
02399
02400 case 'n':
02401
02402 if (EQUAL_STRS(cp, "negmsgs")) {
02403 opt_flags.neg_msgs = TRUE;
02404 }
02405 else if (EQUAL_STRS(cp, "noaggress")) {
02406 opt_flags.aggress = FALSE;
02407 }
02408 else if (EQUAL_STRS(cp, "nobl")) {
02409
02410 # if defined(_ACCEPT_BL)
02411
02412 opt_flags.bottom_load = FALSE;
02413
02414 # else
02415
02416 ntr_msg_queue(0, 744, Log_Warning, 0, "nobl", 'O', ARG_STR_ARG);
02417
02418 # endif
02419
02420 }
02421 else if (EQUAL_STRS(cp, "nofastint")) {
02422
02423 # if defined(_ACCEPT_CMD_O_FASTINT)
02424 opt_flags.set_nofastint_option = TRUE;
02425
02426 if (set_i_option) {
02427 ntr_msg_queue(0, 1192, Log_Warning, 0,
02428 "-i\n-O nofastint\n-i",
02429 0, MULT_STR_ARG);
02430 }
02431 # else
02432 ntr_msg_queue(0, 744, Log_Warning, 0,
02433 "nofastint", 'O', ARG_STR_ARG);
02434 # endif
02435
02436 }
02437 else if (EQUAL_STRS(cp, "nofusion")) {
02438
02439 # if defined(_ACCEPT_CMD_O_FUSION)
02440 opt_flags.fusion = FALSE;
02441 # else
02442 ntr_msg_queue(0, 744, Log_Warning, 0,
02443 "nofusion", 'O', ARG_STR_ARG);
02444 # endif
02445 }
02446 else if (EQUAL_STRS(cp, "noieeeconform")) {
02447
02448 if (target_ieee) {
02449 opt_flags.ieeeconform = FALSE;
02450 set_ieeeconform_option = TRUE;
02451 }
02452 else {
02453 ntr_msg_queue(0, 744, Log_Warning, 0,
02454 "noieeeconform", 'O', ARG_STR_ARG);
02455 }
02456 }
02457 else if (EQUAL_STRS(cp, "nointerchange")) {
02458 opt_flags.nointerchange = TRUE;
02459 }
02460 else if (EQUAL_STRS(cp, "nojump")) {
02461
02462 # if defined(_ACCEPT_CMD_O_JUMP)
02463
02464 opt_flags.jump = FALSE;
02465
02466 # else
02467
02468 ntr_msg_queue(0, 744, Log_Warning, 0,
02469 "nojump", 'O', ARG_STR_ARG);
02470
02471 # endif
02472
02473 }
02474 else if (EQUAL_STRS(cp, "noloopalign")) {
02475
02476 # if defined(_ACCEPT_CMD_O_LOOPALIGN)
02477
02478 opt_flags.loopalign = FALSE;
02479
02480 # else
02481
02482 ntr_msg_queue(0, 744, Log_Warning, 0,
02483 "noloopalign", 'O', ARG_STR_ARG);
02484
02485 # endif
02486
02487 }
02488 else if (EQUAL_STRS(cp, "nomodinline")) {
02489
02490 # if defined(_ACCEPT_INLINE)
02491 opt_flags.modinline = FALSE;
02492 # else
02493
02494 ntr_msg_queue(0, 744, Log_Warning, 0,
02495 "nomodinline", 'O', ARG_STR_ARG);
02496
02497 # endif
02498
02499 }
02500 else if (EQUAL_STRS(cp, "nomsgs")) {
02501 opt_flags.msgs = FALSE;
02502 }
02503 else if (EQUAL_STRS(cp, "nonegmsgs")) {
02504 opt_flags.neg_msgs = FALSE;
02505 }
02506 else if (EQUAL_STRS(cp, "nopattern")) {
02507 opt_flags.pattern = FALSE;
02508 }
02509 else if (EQUAL_STRS(cp, "nooverindex")) {
02510 opt_flags.over_index = FALSE;
02511 }
02512 else if (EQUAL_STRS(cp, "norecurrence")) {
02513 opt_flags.recurrence = FALSE;
02514 }
02515 else if (EQUAL_STRS(cp, "notaskinner")) {
02516
02517 # if defined(_ACCEPT_TASK)
02518
02519 opt_flags.taskinner = FALSE;
02520
02521 # else
02522
02523 ntr_msg_queue(0, 744, Log_Warning, 0,
02524 "notaskinner", 'O', ARG_STR_ARG);
02525
02526 # endif
02527
02528 }
02529 else if (EQUAL_STRS(cp, "nothreshold")) {
02530
02531 # if defined(_ACCEPT_TASK)
02532
02533 opt_flags.threshold = FALSE;
02534
02535 # else
02536
02537 ntr_msg_queue(0, 744, Log_Warning, 0,
02538 "nothreshold", 'O', ARG_STR_ARG);
02539
02540 # endif
02541 }
02542 else if (EQUAL_STRS(cp, "novsearch")) {
02543
02544 # if defined(_ACCEPT_VSEARCH)
02545
02546 opt_flags.vsearch = FALSE;
02547
02548 # else
02549
02550 ntr_msg_queue(0, 744, Log_Warning, 0,
02551 "novsearch", 'O', ARG_STR_ARG);
02552
02553 # endif
02554
02555 }
02556 else if (EQUAL_STRS(cp, "nozeroinc")) {
02557
02558 # if defined(_ACCEPT_CMD_O_ZEROINC)
02559
02560 opt_flags.zeroinc = FALSE;
02561
02562 # else
02563
02564 ntr_msg_queue(0, 744, Log_Warning, 0,
02565 "nozeroinc", 'O', ARG_STR_ARG);
02566
02567 # endif
02568
02569 }
02570 else {
02571 err = TRUE;
02572 }
02573
02574 break;
02575
02576
02577 case 'o':
02578
02579 if (EQUAL_STRS(cp, "overindex")) {
02580 opt_flags.over_index = TRUE;
02581 }
02582 else if (EQUAL_STRS(cp, "opt_info")) {
02583
02584 # if defined(_ACCEPT_CMD_O_OPT_INFO)
02585 opt_flags.opt_info = TRUE;
02586 # else
02587 ntr_msg_queue(0, 744, Log_Warning, 0,
02588 "opt_info", 'O', ARG_STR_ARG);
02589 # endif
02590 }
02591 else {
02592 err = TRUE;
02593 }
02594
02595 break;
02596
02597
02598 case 'p':
02599
02600 if (EQUAL_STRS(cp, "pattern")) {
02601 opt_flags.pattern = TRUE;
02602 set_pattern_option = TRUE;
02603 }
02604 else if (EQUAL_STRS(cp, "pipeline0")) {
02605
02606 # if defined(_ACCEPT_CMD_O_PIPELINE)
02607 opt_flags.pipeline_lvl = 0;
02608 set_pipeline_option = TRUE;
02609 # else
02610 ntr_msg_queue(0, 744, Log_Warning, 0,
02611 "pipeline0", 'O', ARG_STR_ARG);
02612 # endif
02613 }
02614 else if (EQUAL_STRS(cp, "pipeline1")) {
02615
02616 # if defined(_ACCEPT_CMD_O_PIPELINE)
02617 opt_flags.pipeline_lvl = 1;
02618 set_pipeline_option = TRUE;
02619 # else
02620 ntr_msg_queue(0, 744, Log_Warning, 0,
02621 "pipeline1", 'O', ARG_STR_ARG);
02622 # endif
02623 }
02624 else if (EQUAL_STRS(cp, "pipeline2")) {
02625
02626 # if defined(_ACCEPT_CMD_O_PIPELINE)
02627 opt_flags.pipeline_lvl = 2;
02628 set_pipeline_option = TRUE;
02629 # else
02630 ntr_msg_queue(0, 744, Log_Warning, 0,
02631 "pipeline2", 'O', ARG_STR_ARG);
02632 # endif
02633 }
02634 else if (EQUAL_STRS(cp, "pipeline3")) {
02635
02636 # if defined(_ACCEPT_CMD_O_PIPELINE)
02637 opt_flags.pipeline_lvl = 3;
02638 set_pipeline_option = TRUE;
02639 # else
02640 ntr_msg_queue(0, 744, Log_Warning, 0,
02641 "pipeline3", 'O', ARG_STR_ARG);
02642 # endif
02643 }
02644 else {
02645 err = TRUE;
02646 }
02647
02648 break;
02649
02650
02651 case 'r':
02652
02653 if (EQUAL_STRS(cp, "reshape")) {
02654
02655 # if defined(_ACCEPT_CMD_O_RESHAPE)
02656 opt_flags.reshape_all_arrays = TRUE;
02657 opt_flags.reshape = TRUE;
02658 # else
02659 ntr_msg_queue(0, 744, Log_Warning, 0,
02660 "reshape", 'O', ARG_STR_ARG);
02661 # endif
02662 }
02663 else if ((strncmp (cp, "reshape=", 8) == IDENTICAL)) {
02664 cp += 8;
02665 process_reshape_array(cp);
02666 }
02667 else if (! EQUAL_STRS(cp, "recurrence")) {
02668 err = TRUE;
02669 }
02670 else {
02671 opt_flags.recurrence = TRUE;
02672 set_recurrence_option = TRUE;
02673 }
02674
02675 break;
02676
02677
02678 case 's':
02679
02680 if (EQUAL_STRS(cp, "scalar0")) {
02681 opt_flags.scalar_lvl = Scalar_Lvl_0;
02682 set_scalar_option = TRUE;
02683 }
02684 else if (EQUAL_STRS(cp, "scalar1")) {
02685 opt_flags.scalar_lvl = Scalar_Lvl_1;
02686 set_scalar_option = TRUE;
02687 }
02688 else if (EQUAL_STRS(cp, "scalar2")) {
02689 opt_flags.scalar_lvl = Scalar_Lvl_2;
02690 set_scalar_option = TRUE;
02691 }
02692 else if (EQUAL_STRS(cp, "scalar3")) {
02693 opt_flags.scalar_lvl = Scalar_Lvl_3;
02694 set_scalar_option = TRUE;
02695 }
02696 else if (EQUAL_STRS(cp, "split0")) {
02697
02698 # if defined(_ACCEPT_SPLIT)
02699 opt_flags.split_lvl = Split_Lvl_0;
02700 # else
02701 ntr_msg_queue(0, 744, Log_Warning, 0,
02702 "split0", 'O', ARG_STR_ARG);
02703 # endif
02704 }
02705 else if (EQUAL_STRS(cp, "split1")) {
02706
02707 # if defined(_ACCEPT_SPLIT)
02708 opt_flags.split_lvl = Split_Lvl_1;
02709
02710 # else
02711 ntr_msg_queue(0, 744, Log_Warning, 0,
02712 "split1", 'O', ARG_STR_ARG);
02713 # endif
02714 }
02715 else if (EQUAL_STRS(cp, "split2")) {
02716
02717 # if defined(_ACCEPT_SPLIT)
02718 opt_flags.split_lvl = Split_Lvl_2;
02719 # else
02720 ntr_msg_queue(0, 744, Log_Warning, 0,
02721 "split2", 'O', ARG_STR_ARG);
02722 # endif
02723 }
02724 else if (EQUAL_STRS(cp, "shortcircuit0")) {
02725
02726 # if defined(_ACCEPT_SHORTCIRCUIT)
02727 opt_flags.short_circuit_lvl = Short_Circuit_Off;
02728 # else
02729 ntr_msg_queue(0, 744, Log_Warning, 0,
02730 "shortcircuit0", 'O', ARG_STR_ARG);
02731 # endif
02732
02733 }
02734 else if (EQUAL_STRS(cp, "shortcircuit1")) {
02735
02736 # if defined(_ACCEPT_SHORTCIRCUIT)
02737 opt_flags.short_circuit_lvl = Short_Circuit_Present;
02738 # else
02739 ntr_msg_queue(0, 744, Log_Warning, 0,
02740 "shortcircuit1", 'O', ARG_STR_ARG);
02741 # endif
02742
02743 }
02744 else if (EQUAL_STRS(cp, "shortcircuit2")) {
02745
02746 # if defined(_ACCEPT_SHORTCIRCUIT)
02747 opt_flags.short_circuit_lvl = Short_Circuit_Left_Right;
02748 # else
02749 ntr_msg_queue(0, 744, Log_Warning, 0,
02750 "shortcircuit2", 'O', ARG_STR_ARG);
02751 # endif
02752
02753 }
02754 else if (EQUAL_STRS(cp, "shortcircuit3")) {
02755
02756 # if defined(_ACCEPT_SHORTCIRCUIT)
02757 opt_flags.short_circuit_lvl = Short_Circuit_Functions;
02758 # else
02759 ntr_msg_queue(0, 744, Log_Warning, 0,
02760 "shortcircuit3", 'O', ARG_STR_ARG);
02761 # endif
02762
02763 }
02764 else if (EQUAL_STRS(cp, "stream0")) {
02765
02766 if (accept_stream) {
02767 set_stream_option = TRUE;
02768 opt_flags.stream_lvl = Stream_Lvl_0;
02769 }
02770 else {
02771 PRINTMSG (0, 744, Log_Warning, 0, 'O', "stream0");
02772 }
02773 }
02774 else if (EQUAL_STRS(cp, "stream1")) {
02775
02776 if (accept_stream) {
02777 set_stream_option = TRUE;
02778 opt_flags.stream_lvl = Stream_Lvl_1;
02779 }
02780 else {
02781 PRINTMSG (0, 744, Log_Warning, 0, 'O', "stream1");
02782 }
02783 }
02784 else if (EQUAL_STRS(cp, "stream2")) {
02785
02786 if (accept_stream) {
02787 set_stream_option = TRUE;
02788 opt_flags.stream_lvl = Stream_Lvl_2;
02789 }
02790 else {
02791 PRINTMSG (0, 744, Log_Warning, 0, 'O', "stream2");
02792 }
02793 }
02794 else if (EQUAL_STRS(cp, "stream3")) {
02795
02796 if (accept_stream) {
02797 set_stream_option = TRUE;
02798 opt_flags.stream_lvl = Stream_Lvl_3;
02799 }
02800 else {
02801 PRINTMSG (0, 744, Log_Warning, 0, 'O', "stream3");
02802 }
02803 }
02804 else {
02805 err = TRUE;
02806 }
02807
02808 break;
02809
02810
02811 case 't':
02812
02813 if (EQUAL_STRS(cp, "task0")) {
02814
02815 # if defined(_ACCEPT_TASK)
02816
02817 opt_flags.task_lvl = Task_Lvl_0;
02818 set_task_option = TRUE;
02819
02820 # else
02821
02822 ntr_msg_queue(0, 744, Log_Warning, 0, "task0", 'O', ARG_STR_ARG);
02823
02824 # endif
02825
02826 }
02827 else if (EQUAL_STRS(cp, "task1")) {
02828
02829 # if defined(_ACCEPT_TASK)
02830
02831 opt_flags.task_lvl = Task_Lvl_1;
02832 set_task_option = TRUE;
02833
02834 # else
02835
02836 ntr_msg_queue(0, 744, Log_Warning, 0, "task1", 'O', ARG_STR_ARG);
02837
02838 # endif
02839
02840 }
02841 else if (EQUAL_STRS(cp, "task2")) {
02842
02843 # if defined(_ACCEPT_TASK)
02844
02845 opt_flags.task_lvl = Task_Lvl_2;
02846 set_task_option = TRUE;
02847
02848 # else
02849
02850 ntr_msg_queue(0, 744, Log_Warning, 0, "task2", 'O', ARG_STR_ARG);
02851
02852 # endif
02853
02854 }
02855 else if (EQUAL_STRS(cp, "task3")) {
02856
02857 # if defined(_ACCEPT_TASK)
02858
02859 opt_flags.task_lvl = Task_Lvl_3;
02860 set_task_option = TRUE;
02861
02862 # else
02863
02864 ntr_msg_queue(0, 744, Log_Warning, 0, "task3", 'O', ARG_STR_ARG);
02865
02866 # endif
02867
02868 }
02869 else if (EQUAL_STRS(cp, "taskinner")) {
02870
02871 # if defined(_ACCEPT_TASK)
02872
02873 opt_flags.taskinner = TRUE;
02874 set_taskinner_option = TRUE;
02875
02876 # else
02877
02878 ntr_msg_queue(0, 744, Log_Warning, 0,
02879 "taskinner", 'O', ARG_STR_ARG);
02880
02881 # endif
02882
02883 }
02884 else if (EQUAL_STRS(cp, "threshold")) {
02885
02886 # if defined(_ACCEPT_TASK)
02887 opt_flags.threshold = TRUE;
02888 # else
02889 ntr_msg_queue(0, 744, Log_Warning, 0,
02890 "threshold", 'O', ARG_STR_ARG);
02891 # endif
02892 }
02893 else {
02894 err = TRUE;
02895 }
02896
02897 break;
02898
02899
02900 case 'u':
02901
02902 if (EQUAL_STRS(cp, "unroll0")) {
02903
02904 # if defined(_ACCEPT_CMD_O_UNROLL)
02905 opt_flags.unroll_lvl = Unroll_Lvl_0;
02906 # else
02907 ntr_msg_queue(0, 744, Log_Warning, 0,
02908 "unroll0", 'O', ARG_STR_ARG);
02909 # endif
02910 }
02911 else if (EQUAL_STRS(cp, "unroll1")) {
02912
02913 # if defined(_ACCEPT_CMD_O_UNROLL)
02914 opt_flags.unroll_lvl = Unroll_Lvl_1;
02915 # else
02916 ntr_msg_queue(0, 744, Log_Warning, 0,
02917 "unroll1", 'O', ARG_STR_ARG);
02918 # endif
02919 }
02920 else if (EQUAL_STRS(cp, "unroll2")) {
02921
02922 # if defined(_ACCEPT_CMD_O_UNROLL)
02923 opt_flags.unroll_lvl = Unroll_Lvl_2;
02924 # else
02925 ntr_msg_queue(0, 744, Log_Warning, 0,
02926 "unroll2", 'O', ARG_STR_ARG);
02927 # endif
02928 }
02929 else {
02930 err = TRUE;
02931 }
02932 break;
02933
02934
02935 case 'v':
02936
02937 if (EQUAL_STRS(cp, "vector0")) {
02938
02939 # if defined(_ACCEPT_VECTOR)
02940 opt_flags.vector_lvl = Vector_Lvl_0;
02941 set_vector_option = TRUE;
02942 # else
02943 ntr_msg_queue(0, 744, Log_Warning, 0,
02944 "vector0", 'O', ARG_STR_ARG);
02945 # endif
02946
02947 }
02948 else if (EQUAL_STRS(cp, "vector1")) {
02949
02950 # if defined(_ACCEPT_VECTOR)
02951
02952 opt_flags.vector_lvl = Vector_Lvl_1;
02953 set_vector_option = TRUE;
02954
02955 # else
02956
02957 ntr_msg_queue(0, 744, Log_Warning, 0,
02958 "vector1", 'O', ARG_STR_ARG);
02959
02960 # endif
02961
02962 }
02963 else if (EQUAL_STRS(cp, "vector2")) {
02964
02965 # if defined(_ACCEPT_VECTOR)
02966
02967 opt_flags.vector_lvl = Vector_Lvl_2;
02968 set_vector_option = TRUE;
02969
02970 # else
02971
02972 ntr_msg_queue(0, 744, Log_Warning, 0,
02973 "vector2", 'O', ARG_STR_ARG);
02974
02975 # endif
02976
02977 }
02978 else if (EQUAL_STRS(cp, "vector3")) {
02979
02980 # if defined(_ACCEPT_VECTOR)
02981
02982 opt_flags.vector_lvl = Vector_Lvl_3;
02983 set_vector_option = TRUE;
02984
02985 # else
02986
02987 ntr_msg_queue(0, 744, Log_Warning, 0,
02988 "vector3", 'O', ARG_STR_ARG);
02989
02990 # endif
02991
02992 }
02993 else if (EQUAL_STRS(cp, "vsearch")) {
02994
02995 # if defined(_ACCEPT_VSEARCH)
02996
02997 opt_flags.vsearch = TRUE;
02998 set_vsearch_option = TRUE;
02999
03000 # else
03001
03002 ntr_msg_queue(0, 744, Log_Warning, 0,
03003 "vsearch", 'O', ARG_STR_ARG);
03004
03005 # endif
03006
03007 }
03008 else {
03009 err = TRUE;
03010 }
03011
03012 break;
03013
03014
03015 case 'z':
03016
03017 if (! EQUAL_STRS(cp, "zeroinc")) {
03018 err = TRUE;
03019 }
03020 else {
03021
03022 # if defined(_ACCEPT_CMD_O_ZEROINC)
03023
03024 opt_flags.zeroinc = TRUE;
03025 set_zeroinc_option = TRUE;
03026
03027 # else
03028
03029 ntr_msg_queue(0, 744, Log_Warning, 0,
03030 "zeroinc", 'O', ARG_STR_ARG);
03031
03032 # endif
03033
03034 }
03035
03036 break;
03037
03038
03039 default:
03040 err = TRUE;
03041 break;
03042 }
03043
03044
03045
03046
03047 if (err) {
03048
03049 if (first && (argc == optind)) {
03050
03051
03052
03053
03054
03055
03056
03057
03058
03059
03060
03061
03062 ntr_msg_queue(0, 1221, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
03063 --optind;
03064 }
03065 else {
03066 ntr_msg_queue(0, 78, Log_Error, 0, cp, 'O', ARG_STR_ARG);
03067 }
03068 }
03069
03070 first = FALSE;
03071 }
03072
03073 TRACE (Func_Exit, "process_O_option", NULL);
03074
03075 return;
03076
03077 }
03078
03079
03080
03081
03082
03083
03084
03085
03086
03087
03088
03089
03090
03091
03092
03093
03094
03095
03096
03097 static void validate_O_option (void)
03098
03099 {
03100 char msg_str[30];
03101 boolean option_conflict = FALSE;
03102 int scalar;
03103 char *str;
03104 int task;
03105
03106 # if defined(_ACCEPT_VECTOR)
03107 int vector;
03108 # endif
03109
03110
03111 TRACE (Func_Entry, "validate_O_option", NULL);
03112
03113
03114
03115
03116
03117 if (set_support_lvl_option) {
03118
03119 if (set_scalar_option) {
03120 ntr_msg_queue(0, 1535, Log_Error, 0,
03121 scalar_lvl_str[opt_flags.scalar_lvl],
03122 (long) opt_flags.support_lvl, ARG_STR_ARG);
03123 option_conflict = TRUE;
03124 }
03125
03126 if (set_vector_option) {
03127 ntr_msg_queue(0, 1535, Log_Error, 0,
03128 vector_lvl_str[opt_flags.vector_lvl],
03129 (long) opt_flags.support_lvl, ARG_STR_ARG);
03130 option_conflict = TRUE;
03131 }
03132
03133 if (set_task_option) {
03134 ntr_msg_queue(0, 1535, Log_Error, 0,
03135 task_lvl_str[opt_flags.task_lvl],
03136 (long) opt_flags.support_lvl, ARG_STR_ARG);
03137 option_conflict = TRUE;
03138 }
03139 }
03140
03141 if (option_conflict) {
03142 goto EXIT;
03143 }
03144
03145
03146
03147
03148
03149
03150
03151
03152 # ifdef _ACCEPT_TASK
03153
03154 if (set_taskinner_option && opt_flags.taskinner) {
03155
03156 if (set_task_option || set_support_lvl_option) {
03157
03158 if (opt_flags.task_lvl < Task_Lvl_2) {
03159 ntr_msg_queue(0, 1182, Log_Error, 0, (char *) NULL, 0, NO_ARG);
03160 }
03161 }
03162 else {
03163 ntr_msg_queue(0, 1182, Log_Error, 0, (char *) NULL, 0, NO_ARG);
03164 }
03165 }
03166
03167 # endif
03168
03169
03170 # if defined(_ACCEPT_TASK) && defined(_ACCEPT_VECTOR)
03171
03172 if (! set_vector_option && ! set_scalar_option && ! set_task_option) {
03173 goto CONTINUE;
03174 }
03175
03176 if (set_vector_option && set_scalar_option && set_task_option) {
03177
03178 if (opt_flags.scalar_lvl >= opt_flags.vector_lvl &&
03179 opt_flags.vector_lvl >= opt_flags.task_lvl) {
03180
03181
03182 }
03183 else if (opt_flags.task_lvl > Task_Lvl_1 &&
03184 opt_flags.task_lvl > opt_flags.vector_lvl) {
03185 msg_str[0] = NULL_CHAR;
03186 strcpy(msg_str, vector_lvl_str[opt_flags.vector_lvl]);
03187 strcpy(&msg_str[7], "\n");
03188 strcpy(&msg_str[8], task_lvl_str[opt_flags.task_lvl]);
03189 ntr_msg_queue(0, 99, Log_Error, 0, msg_str, 0, MULT_STR_ARG);
03190 }
03191 else if (opt_flags.scalar_lvl == Scalar_Lvl_2 &&
03192 opt_flags.vector_lvl == Vector_Lvl_3) {
03193
03194
03195
03196 }
03197 else if (opt_flags.scalar_lvl < opt_flags.vector_lvl) {
03198 msg_str[0] = NULL_CHAR;
03199 strcpy(msg_str, scalar_lvl_str[opt_flags.scalar_lvl]);
03200 strcpy(&msg_str[7], "\n");
03201 strcpy(&msg_str[8], vector_lvl_str[opt_flags.vector_lvl]);
03202 ntr_msg_queue(0, 99, Log_Error, 0, msg_str, 0, MULT_STR_ARG);
03203 }
03204 }
03205 else if (set_vector_option && set_scalar_option) {
03206
03207 if (opt_flags.scalar_lvl == Scalar_Lvl_2 &&
03208 opt_flags.vector_lvl == Vector_Lvl_3) {
03209
03210
03211
03212
03213 }
03214 else if (opt_flags.scalar_lvl < opt_flags.vector_lvl) {
03215 msg_str[0] = NULL_CHAR;
03216 strcpy(msg_str, scalar_lvl_str[opt_flags.scalar_lvl]);
03217 strcpy(&msg_str[7], "\n");
03218 strcpy(&msg_str[8], vector_lvl_str[opt_flags.vector_lvl]);
03219 ntr_msg_queue(0, 99, Log_Error, 0, msg_str, 0, MULT_STR_ARG);
03220 }
03221 else if (opt_flags.task_lvl > opt_flags.vector_lvl &&
03222 opt_flags.task_lvl > Task_Lvl_1) {
03223 task = (opt_flags.vector_lvl == Vector_Lvl_0) ?
03224 Task_Lvl_1 : opt_flags.vector_lvl;
03225
03226 msg_str[0] = NULL_CHAR;
03227 strcpy(msg_str, scalar_lvl_str[opt_flags.scalar_lvl]);
03228 strcpy(&msg_str[7], "\n");
03229 strcpy(&msg_str[8], vector_lvl_str[opt_flags.vector_lvl]);
03230 strcpy(&msg_str[15], "\n");
03231 strcpy(&msg_str[16], task_lvl_str[opt_flags.task_lvl]);
03232 strcpy(&msg_str[21], "\n");
03233 strcpy(&msg_str[22], task_lvl_str[task]);
03234
03235 ntr_msg_queue(0, 1064, Log_Error, 0, msg_str, 0, MULT_STR_ARG);
03236 opt_flags.task_lvl = task;
03237 }
03238 }
03239 else if (set_scalar_option && set_task_option) {
03240
03241 if (opt_flags.task_lvl == Task_Lvl_3 &&
03242 opt_flags.scalar_lvl == Scalar_Lvl_2) {
03243
03244
03245
03246 if (opt_flags.vector_lvl != Vector_Lvl_3) {
03247 msg_str[0] = NULL_CHAR;
03248 strcpy(msg_str, scalar_lvl_str[opt_flags.scalar_lvl]);
03249 strcpy(&msg_str[7], "\n");
03250 strcpy(&msg_str[8], task_lvl_str[opt_flags.task_lvl]);
03251 strcpy(&msg_str[13], "\n");
03252 strcpy(&msg_str[14], vector_lvl_str[opt_flags.vector_lvl]);
03253 strcpy(&msg_str[21], "\n");
03254 strcpy(&msg_str[22], vector_lvl_str[Vector_Lvl_3]);
03255
03256 ntr_msg_queue(0, 1064, Log_Error, 0, msg_str, 0, MULT_STR_ARG);
03257 opt_flags.vector_lvl = Vector_Lvl_3;
03258 }
03259 }
03260 else if (opt_flags.task_lvl <= Task_Lvl_1) {
03261
03262
03263
03264 if (opt_flags.vector_lvl > opt_flags.scalar_lvl) {
03265 vector = opt_flags.scalar_lvl;
03266 msg_str[0] = NULL_CHAR;
03267 strcpy(msg_str, scalar_lvl_str[opt_flags.scalar_lvl]);
03268 strcpy(&msg_str[7], "\n");
03269 strcpy(&msg_str[8], task_lvl_str[opt_flags.task_lvl]);
03270 strcpy(&msg_str[13], "\n");
03271 strcpy(&msg_str[14], vector_lvl_str[opt_flags.vector_lvl]);
03272 strcpy(&msg_str[21], "\n");
03273 strcpy(&msg_str[22], vector_lvl_str[vector]);
03274
03275 ntr_msg_queue(0, 1064, Log_Error, 0, msg_str, 0, MULT_STR_ARG);
03276 opt_flags.vector_lvl = vector;
03277 }
03278 }
03279 else if (opt_flags.task_lvl > opt_flags.scalar_lvl) {
03280 msg_str[0] = NULL_CHAR;
03281 strcpy(msg_str, scalar_lvl_str[opt_flags.scalar_lvl]);
03282 strcpy(&msg_str[7], "\n");
03283 strcpy(&msg_str[8], task_lvl_str[opt_flags.task_lvl]);
03284 ntr_msg_queue(0, 99, Log_Error, 0, msg_str, 0, MULT_STR_ARG);
03285 }
03286 else if (opt_flags.task_lvl > opt_flags.vector_lvl) {
03287 vector = opt_flags.task_lvl;
03288 msg_str[0] = NULL_CHAR;
03289 strcpy(msg_str, scalar_lvl_str[opt_flags.scalar_lvl]);
03290 strcpy(&msg_str[7], "\n");
03291 strcpy(&msg_str[8], task_lvl_str[opt_flags.task_lvl]);
03292 strcpy(&msg_str[13], "\n");
03293 strcpy(&msg_str[14], vector_lvl_str[opt_flags.vector_lvl]);
03294 strcpy(&msg_str[21], "\n");
03295 strcpy(&msg_str[22], vector_lvl_str[vector]);
03296 ntr_msg_queue(0, 1064, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03297
03298 opt_flags.vector_lvl = vector;
03299 }
03300 }
03301 else if (set_vector_option && set_task_option) {
03302
03303 if (opt_flags.task_lvl > Task_Lvl_1 &&
03304 opt_flags.task_lvl > opt_flags.vector_lvl) {
03305 msg_str[0] = NULL_CHAR;
03306 strcpy(msg_str, vector_lvl_str[opt_flags.vector_lvl]);
03307 strcpy(&msg_str[7], "\n");
03308 strcpy(&msg_str[8], task_lvl_str[opt_flags.task_lvl]);
03309 ntr_msg_queue(0, 99, Log_Error, 0, msg_str, 0, MULT_STR_ARG);
03310 }
03311 else if (opt_flags.vector_lvl > opt_flags.scalar_lvl) {
03312
03313 if (opt_flags.scalar_lvl == Scalar_Lvl_2) {
03314
03315
03316
03317 }
03318 else {
03319 scalar = (opt_flags.vector_lvl == Vector_Lvl_3) ?
03320 Scalar_Lvl_2 : opt_flags.vector_lvl;
03321 msg_str[0] = NULL_CHAR;
03322 strcpy(msg_str, vector_lvl_str[opt_flags.vector_lvl]);
03323 strcpy(&msg_str[7], "\n");
03324 strcpy(&msg_str[8], task_lvl_str[opt_flags.task_lvl]);
03325 strcpy(&msg_str[13], "\n");
03326 strcpy(&msg_str[14], scalar_lvl_str[opt_flags.scalar_lvl]);
03327 strcpy(&msg_str[21], "\n");
03328 strcpy(&msg_str[22], scalar_lvl_str[scalar]);
03329 ntr_msg_queue(0, 1064, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03330
03331 opt_flags.scalar_lvl = scalar;
03332 }
03333 }
03334 }
03335 else if (set_scalar_option) {
03336
03337 if (opt_flags.vector_lvl > opt_flags.scalar_lvl) {
03338 vector = opt_flags.scalar_lvl;
03339 msg_str[0] = NULL_CHAR;
03340 strcpy(msg_str, scalar_lvl_str[opt_flags.scalar_lvl]);
03341 strcpy(&msg_str[7], "\n");
03342 strcpy(&msg_str[8], vector_lvl_str[opt_flags.vector_lvl]);
03343 strcpy(&msg_str[15], "\n");
03344 strcpy(&msg_str[16], vector_lvl_str[vector]);
03345
03346 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03347 opt_flags.vector_lvl = vector;
03348 }
03349
03350 if (opt_flags.task_lvl > opt_flags.vector_lvl &&
03351 opt_flags.task_lvl > Task_Lvl_1) {
03352 task = (opt_flags.vector_lvl == Vector_Lvl_0) ?
03353 Task_Lvl_1 : opt_flags.vector_lvl;
03354 msg_str[0] = NULL_CHAR;
03355 strcpy(msg_str, vector_lvl_str[opt_flags.vector_lvl]);
03356 strcpy(&msg_str[7], "\n");
03357 strcpy(&msg_str[8], task_lvl_str[opt_flags.task_lvl]);
03358 strcpy(&msg_str[13], "\n");
03359 strcpy(&msg_str[14], task_lvl_str[task]);
03360
03361 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03362 opt_flags.task_lvl = task;
03363 }
03364 }
03365 else if (set_vector_option) {
03366
03367 if (opt_flags.vector_lvl > opt_flags.scalar_lvl &&
03368 opt_flags.scalar_lvl != Scalar_Lvl_2) {
03369
03370
03371
03372 scalar = (opt_flags.vector_lvl == Vector_Lvl_3) ?
03373 Scalar_Lvl_2 : opt_flags.vector_lvl;
03374 msg_str[0] = NULL_CHAR;
03375 strcpy(msg_str, vector_lvl_str[opt_flags.vector_lvl]);
03376 strcpy(&msg_str[7], "\n");
03377 strcpy(&msg_str[8], scalar_lvl_str[opt_flags.scalar_lvl]);
03378 strcpy(&msg_str[15], "\n");
03379 strcpy(&msg_str[16], scalar_lvl_str[scalar]);
03380
03381 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03382 opt_flags.scalar_lvl = scalar;
03383 }
03384
03385 if (opt_flags.task_lvl > opt_flags.vector_lvl &&
03386 opt_flags.task_lvl > Task_Lvl_1) {
03387
03388 task = (opt_flags.vector_lvl == Vector_Lvl_0) ?
03389 Task_Lvl_1 : opt_flags.vector_lvl;
03390 msg_str[0] = NULL_CHAR;
03391 strcpy(msg_str, vector_lvl_str[opt_flags.vector_lvl]);
03392 strcpy(&msg_str[7], "\n");
03393 strcpy(&msg_str[8], task_lvl_str[opt_flags.task_lvl]);
03394 strcpy(&msg_str[13], "\n");
03395 strcpy(&msg_str[14], task_lvl_str[task]);
03396
03397 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03398 opt_flags.task_lvl = task;
03399 }
03400 }
03401 else if (set_task_option && opt_flags.task_lvl > Task_Lvl_1) {
03402
03403 if (opt_flags.scalar_lvl < opt_flags.task_lvl &&
03404 opt_flags.scalar_lvl != Scalar_Lvl_2) {
03405 scalar = (opt_flags.task_lvl == Task_Lvl_3) ?
03406 Scalar_Lvl_2 : opt_flags.task_lvl;
03407 msg_str[0] = NULL_CHAR;
03408 strcpy(msg_str, task_lvl_str[opt_flags.task_lvl]);
03409 strcpy(&msg_str[5], "\n");
03410 strcpy(&msg_str[6], scalar_lvl_str[opt_flags.scalar_lvl]);
03411 strcpy(&msg_str[13], "\n");
03412 strcpy(&msg_str[14], scalar_lvl_str[scalar]);
03413
03414 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03415 opt_flags.scalar_lvl = scalar;
03416 }
03417
03418 if (opt_flags.task_lvl > opt_flags.vector_lvl) {
03419 vector = opt_flags.task_lvl;
03420 msg_str[0] = NULL_CHAR;
03421 strcpy(msg_str, task_lvl_str[opt_flags.task_lvl]);
03422 strcpy(&msg_str[5], "\n");
03423 strcpy(&msg_str[6], vector_lvl_str[opt_flags.vector_lvl]);
03424 strcpy(&msg_str[13], "\n");
03425 strcpy(&msg_str[14], vector_lvl_str[vector]);
03426
03427 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03428 opt_flags.vector_lvl = vector;
03429 }
03430 }
03431
03432 # elif defined(_ACCEPT_TASK) && !defined(_ACCEPT_VECTOR)
03433
03434 if (opt_flags.task_lvl > Task_Lvl_1) {
03435
03436
03437
03438 if (set_scalar_option && set_task_option) {
03439
03440 if (opt_flags.task_lvl > opt_flags.scalar_lvl &&
03441 opt_flags.scalar_lvl != Scalar_Lvl_2) {
03442
03443
03444
03445 msg_str[0] = NULL_CHAR;
03446 strcpy(msg_str, scalar_lvl_str[opt_flags.scalar_lvl]);
03447 strcpy(&msg_str[7], "\n");
03448 strcpy(&msg_str[8], task_lvl_str[opt_flags.task_lvl]);
03449 ntr_msg_queue(0, 99, Log_Error, 0, msg_str, 0, MULT_STR_ARG);
03450 }
03451 }
03452 else if (set_scalar_option) {
03453
03454 if (opt_flags.task_lvl > opt_flags.scalar_lvl) {
03455 task = (opt_flags.scalar_lvl == Scalar_Lvl_0) ?
03456 Task_Lvl_1 : opt_flags.scalar_lvl;
03457 msg_str[0] = NULL_CHAR;
03458 strcpy(msg_str, scalar_lvl_str[opt_flags.scalar_lvl]);
03459 strcpy(&msg_str[7], "\n");
03460 strcpy(&msg_str[8], task_lvl_str[opt_flags.task_lvl]);
03461 strcpy(&msg_str[13], "\n");
03462 strcpy(&msg_str[14], task_lvl_str[task]);
03463
03464 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03465 opt_flags.task_lvl = task;
03466 }
03467 }
03468 else if (set_task_option) {
03469
03470 if (opt_flags.task_lvl > opt_flags.scalar_lvl) {
03471 scalar = (opt_flags.task_lvl == Task_Lvl_3) ?
03472 Scalar_Lvl_2 : opt_flags.task_lvl;
03473 msg_str[0] = NULL_CHAR;
03474 strcpy(msg_str, task_lvl_str[opt_flags.task_lvl]);
03475 strcpy(&msg_str[5], "\n");
03476 strcpy(&msg_str[6], scalar_lvl_str[opt_flags.scalar_lvl]);
03477 strcpy(&msg_str[13], "\n");
03478 strcpy(&msg_str[14], scalar_lvl_str[scalar]);
03479
03480 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03481 opt_flags.scalar_lvl = scalar;
03482 }
03483 }
03484 }
03485
03486 # endif
03487 CONTINUE:
03488
03489
03490 if (opt_flags.scalar_lvl == Scalar_Lvl_0) {
03491
03492 if (set_aggress_option && opt_flags.aggress) {
03493 str = (set_scalar_option) ? "scalar0" : "0";
03494 strcat(str, "\n");
03495 strcat(str, "aggress");
03496 ntr_msg_queue(0, 99, Log_Error, 0, str, 0, MULT_STR_ARG);
03497 }
03498
03499 opt_flags.aggress = FALSE;
03500
03501 if (set_bottom_load_option && opt_flags.bottom_load) {
03502 str = (set_scalar_option) ? "scalar0" : "0";
03503 strcat(str, "\n");
03504 strcat(str, "bl");
03505 ntr_msg_queue(0, 99, Log_Error, 0, str, 0, MULT_STR_ARG);
03506 }
03507
03508 opt_flags.bottom_load = FALSE;
03509
03510 if (set_recurrence_option && opt_flags.recurrence) {
03511 str = (set_scalar_option) ? "scalar0" : "0";
03512 strcat(str, "\n");
03513 strcat(str, "recurrence");
03514 ntr_msg_queue(0, 99, Log_Error, 0, str, 0, MULT_STR_ARG);
03515 }
03516
03517 opt_flags.recurrence = FALSE;
03518
03519 if (set_zeroinc_option && opt_flags.zeroinc) {
03520 str = (set_scalar_option) ? "scalar0" : "0";
03521 strcat(str, "\n");
03522 strcat(str, "zeroinc");
03523 ntr_msg_queue(0, 99, Log_Error, 0, str, 0, MULT_STR_ARG);
03524 }
03525
03526 opt_flags.zeroinc = FALSE;
03527 }
03528 else if (opt_flags.scalar_lvl == Scalar_Lvl_3) {
03529
03530 if (! set_bottom_load_option) {
03531 opt_flags.bottom_load = TRUE;
03532 }
03533 }
03534
03535 # if defined(_ACCEPT_VECTOR)
03536
03537 if (opt_flags.vector_lvl == Vector_Lvl_0) {
03538
03539 if (set_vsearch_option && opt_flags.vsearch) {
03540 str = (set_vector_option) ? "vector0" : "0";
03541 strcat(str, "\n");
03542 strcat(str, "vsearch");
03543 ntr_msg_queue(0, 99, Log_Error, 0, str, 0, MULT_STR_ARG);
03544 }
03545
03546 opt_flags.vsearch = FALSE;
03547
03548 # if defined(_TARGET_OS_UNICOS)
03549
03550 if (set_pattern_option && opt_flags.pattern) {
03551 str = (set_vector_option) ? "vector0" : "0";
03552 strcat(str, "\n");
03553 strcat(str, "pattern");
03554 ntr_msg_queue(0, 99, Log_Error, 0, str, 0, MULT_STR_ARG);
03555 }
03556
03557 opt_flags.pattern = FALSE;
03558 # endif
03559
03560 }
03561
03562 # if defined(_TARGET_OS_UNICOS)
03563 else if (opt_flags.vector_lvl == Vector_Lvl_1) {
03564
03565 if (set_pattern_option && opt_flags.pattern) {
03566 str = (set_vector_option) ? "vector1" : "1";
03567 strcpy(msg_str, "\n");
03568 strcpy(msg_str, "pattern");
03569 ntr_msg_queue(0, 99, Log_Error, 0, msg_str, 0, MULT_STR_ARG);
03570 }
03571
03572 opt_flags.pattern = FALSE;
03573 }
03574 # endif
03575
03576 # endif
03577
03578 # if defined(_ACCEPT_STREAM)
03579 if (opt_flags.stream_lvl > Stream_Lvl_0 && cmd_line_flags.co_array_fortran) {
03580 PRINTMSG (0, 1570, Log_Error, 0, "-Z");
03581 }
03582
03583 if (accept_stream && opt_flags.stream_lvl > Stream_Lvl_0) {
03584
03585
03586
03587
03588 if (opt_flags.stream_lvl > opt_flags.scalar_lvl &&
03589 opt_flags.scalar_lvl < Scalar_Lvl_2) {
03590
03591 if (set_scalar_option && set_stream_option) {
03592
03593
03594
03595 msg_str[0] = NULL_CHAR;
03596 strcpy(msg_str, stream_lvl_str[opt_flags.stream_lvl]);
03597 strcpy(&msg_str[7], "\n");
03598 strcpy(&msg_str[8], scalar_lvl_str[opt_flags.scalar_lvl]);
03599 ntr_msg_queue(0, 99, Log_Error, 0, msg_str, 0, MULT_STR_ARG);
03600 option_conflict = TRUE;
03601 }
03602 else if (!set_scalar_option && !set_stream_option) {
03603
03604
03605
03606
03607 opt_flags.stream_lvl = opt_flags.scalar_lvl;
03608 }
03609 else if (set_scalar_option) {
03610 msg_str[0] = NULL_CHAR;
03611 strcpy(msg_str, scalar_lvl_str[opt_flags.scalar_lvl]);
03612 strcpy(&msg_str[7], "\n");
03613 strcpy(&msg_str[8], stream_lvl_str[opt_flags.stream_lvl]);
03614 strcpy(&msg_str[15], "\n");
03615 strcpy(&msg_str[16], stream_lvl_str[opt_flags.scalar_lvl]);
03616
03617 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03618 opt_flags.stream_lvl = opt_flags.scalar_lvl;
03619 }
03620 else if (set_stream_option) {
03621 msg_str[0] = NULL_CHAR;
03622 strcpy(msg_str, stream_lvl_str[opt_flags.stream_lvl]);
03623 strcpy(&msg_str[7], "\n");
03624 strcpy(&msg_str[8], scalar_lvl_str[opt_flags.scalar_lvl]);
03625 strcpy(&msg_str[15], "\n");
03626
03627 if (opt_flags.stream_lvl == Stream_Lvl_3) {
03628 strcpy(&msg_str[16], scalar_lvl_str[Stream_Lvl_2]);
03629
03630 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03631 opt_flags.scalar_lvl = Stream_Lvl_2;
03632 }
03633 else {
03634 strcpy(&msg_str[16], scalar_lvl_str[opt_flags.stream_lvl]);
03635
03636 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03637 opt_flags.scalar_lvl = opt_flags.stream_lvl;
03638 }
03639 }
03640 }
03641
03642
03643 if (option_conflict) {
03644 goto EXIT;
03645 }
03646
03647 if (opt_flags.stream_lvl > opt_flags.vector_lvl &&
03648 opt_flags.vector_lvl < Vector_Lvl_2) {
03649
03650 if (set_vector_option && set_stream_option) {
03651
03652
03653
03654 msg_str[0] = NULL_CHAR;
03655 strcpy(msg_str, stream_lvl_str[opt_flags.stream_lvl]);
03656 strcpy(&msg_str[7], "\n");
03657 strcpy(&msg_str[8], vector_lvl_str[opt_flags.vector_lvl]);
03658 ntr_msg_queue(0, 99, Log_Error, 0, msg_str, 0, MULT_STR_ARG);
03659 option_conflict = TRUE;
03660 }
03661 else if (!set_vector_option && !set_stream_option) {
03662
03663
03664
03665
03666 opt_flags.stream_lvl = opt_flags.vector_lvl;
03667 }
03668 else if (set_vector_option) {
03669 msg_str[0] = NULL_CHAR;
03670 strcpy(msg_str, vector_lvl_str[opt_flags.vector_lvl]);
03671 strcpy(&msg_str[7], "\n");
03672 strcpy(&msg_str[8], stream_lvl_str[opt_flags.stream_lvl]);
03673 strcpy(&msg_str[15], "\n");
03674 strcpy(&msg_str[16], stream_lvl_str[opt_flags.vector_lvl]);
03675
03676 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03677 opt_flags.stream_lvl = opt_flags.vector_lvl;
03678 }
03679 else if (set_stream_option) {
03680 msg_str[0] = NULL_CHAR;
03681 strcpy(msg_str, stream_lvl_str[opt_flags.stream_lvl]);
03682 strcpy(&msg_str[7], "\n");
03683 strcpy(&msg_str[8], vector_lvl_str[opt_flags.vector_lvl]);
03684 strcpy(&msg_str[15], "\n");
03685
03686 if (opt_flags.stream_lvl == Stream_Lvl_3) {
03687 strcpy(&msg_str[16], vector_lvl_str[Stream_Lvl_2]);
03688
03689 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03690 opt_flags.vector_lvl = Stream_Lvl_2;
03691 }
03692 else {
03693 strcpy(&msg_str[16], vector_lvl_str[opt_flags.stream_lvl]);
03694
03695 ntr_msg_queue(0, 1068, Log_Warning, 0, msg_str, 0, MULT_STR_ARG);
03696 opt_flags.vector_lvl = opt_flags.stream_lvl;
03697 }
03698 }
03699 }
03700
03701 if (option_conflict) {
03702 goto EXIT;
03703 }
03704 }
03705
03706 # endif
03707
03708 # if defined(_ACCEPT_INLINE)
03709
03710 if (opt_flags.inline_lvl == Inline_Lvl_0 &&
03711 set_inlinefrom_option) {
03712 opt_flags.inline_lvl = Inline_Lvl_4;
03713 }
03714
03715 if (set_debug_option) {
03716 opt_flags.inline_lvl = Inline_Lvl_0;
03717 }
03718
03719 # endif
03720
03721 # if defined(_TARGET_OS_UNICOS)
03722
03723
03724 if (opt_flags.task_lvl == Task_Lvl_0) {
03725 dump_flags.open_mp = FALSE;
03726 }
03727 else {
03728 dump_flags.open_mp = TRUE;
03729 }
03730
03731 # endif
03732
03733 EXIT:
03734
03735 TRACE (Func_Exit, "validate_O_option", NULL);
03736
03737 return;
03738
03739 }
03740
03741
03742
03743
03744
03745
03746
03747
03748
03749
03750
03751
03752
03753
03754
03755
03756
03757
03758
03759 static void process_t_option (char *optargs)
03760
03761 {
03762 char *opt_chk;
03763 int trunc;
03764
03765
03766 TRACE (Func_Entry, "process_t_option", NULL);
03767
03768
03769
03770 if (set_round_option) {
03771 ntr_msg_queue(0, 75, Log_Warning, 0, "-t", 0, STR_ARG);
03772 set_round_option = FALSE;
03773 }
03774
03775
03776
03777 opt_chk = optargs;
03778
03779 while (isdigit(*opt_chk)) {
03780 opt_chk++;
03781 }
03782
03783 trunc = atoi (optargs);
03784
03785 if (*opt_chk != EOS || trunc > MAX_TRUNCATION_BITS) {
03786 ntr_msg_queue(0, 78, Log_Error, 0, optargs, 't', ARG_STR_ARG);
03787 }
03788 else {
03789
03790 # if defined(_TARGET_OS_SOLARIS)
03791
03792 if (trunc > 0) {
03793 ntr_msg_queue(0, 744, Log_Warning, 0, optargs, 't', ARG_STR_ARG);
03794 trunc = 0;
03795 }
03796 # endif
03797
03798 on_off_flags.round_mult_operations = FALSE;
03799 cmd_line_flags.truncate_bits = trunc;
03800 }
03801
03802 set_trunc_option = TRUE;
03803
03804 TRACE (Func_Exit, "process_t_option", NULL);
03805
03806 return;
03807
03808 }
03809
03810
03811
03812
03813
03814
03815
03816
03817
03818
03819
03820
03821
03822
03823
03824
03825
03826
03827 static void process_u_option (char *optargs)
03828
03829 {
03830 char *cp;
03831 boolean non_debug_ok = FALSE;
03832
03833 TRACE (Func_Entry, "process_u_option", NULL);
03834
03835 while (*optargs != EOS) {
03836 for (cp = optargs;
03837 *optargs != BLANK && *optargs != COMMA && *optargs != EOS;
03838 ++optargs);
03839
03840 if (*optargs != EOS) {
03841 *optargs = EOS;
03842 *optargs++;
03843 }
03844
03845 if (EQUAL_STRS(cp, "help")) {
03846 dump_flags.help_dbg = TRUE;
03847 non_debug_ok = TRUE;
03848 }
03849 else if (EQUAL_STRS(cp, "abort_ansi")) {
03850 dump_flags.abort_on_ansi = TRUE;
03851 non_debug_ok = TRUE;
03852 }
03853 else if (EQUAL_STRS(cp, "no_dim_pad")) {
03854 dump_flags.no_dimension_padding = TRUE;
03855 non_debug_ok = TRUE;
03856 }
03857 else if (EQUAL_STRS(cp, "show")) {
03858 dump_flags.show_cmd_line = TRUE;
03859 non_debug_ok = TRUE;
03860 }
03861 else if (EQUAL_STRS(cp, "mp")) {
03862 dump_flags.mp = TRUE;
03863 non_debug_ok = TRUE;
03864 }
03865 else if (EQUAL_STRS(cp, "mod_version")) {
03866 dump_flags.mod_version = TRUE;
03867 non_debug_ok = TRUE;
03868 }
03869 else if (EQUAL_STRS(cp, "open_mp")) {
03870 dump_flags.open_mp = TRUE;
03871 non_debug_ok = TRUE;
03872 }
03873 else if (EQUAL_STRS(cp, "dsm")) {
03874 dump_flags.dsm = TRUE;
03875 non_debug_ok = TRUE;
03876 }
03877 else if (EQUAL_STRS(cp, "cray_compatible")) {
03878 dump_flags.cray_compatible = TRUE;
03879 non_debug_ok = TRUE;
03880 }
03881
03882 # if defined(_TARGET_PACK_HALF_WORD_TYPES)
03883 else if (EQUAL_STRS(cp, "pack_half_word")) {
03884 dump_flags.pack_half_word = TRUE;
03885 non_debug_ok = TRUE;
03886 }
03887 # endif
03888 else if (EQUAL_STRS(cp, "fe_version")) {
03889 printf("This is frontend %s of release %s\n",
03890 frontend_version, release_level);
03891 non_debug_ok = TRUE;
03892 }
03893 # if defined(COARRAY_FORTRAN)
03894 else if (EQUAL_STRS(cp, "fmm1")) {
03895 dump_flags.f_minus_minus = TRUE;
03896 cmd_line_flags.co_array_fortran = TRUE;
03897 dump_flags.fmm1 = TRUE;
03898 non_debug_ok = TRUE;
03899 }
03900 else if (EQUAL_STRS(cp, "fmm2")) {
03901 dump_flags.f_minus_minus = TRUE;
03902 cmd_line_flags.co_array_fortran = TRUE;
03903 dump_flags.fmm2 = TRUE;
03904 non_debug_ok = TRUE;
03905 }
03906 else if (EQUAL_STRS(cp, "fmm")) {
03907 dump_flags.f_minus_minus = TRUE;
03908 cmd_line_flags.co_array_fortran = TRUE;
03909 dump_flags.fmm1 = TRUE;
03910 non_debug_ok = TRUE;
03911 }
03912 # endif
03913 else if (EQUAL_STRS(cp, "no_mod_output")) {
03914 dump_flags.no_module_output = TRUE;
03915 non_debug_ok = TRUE;
03916 }
03917 else if ((strncmp (cp, "preinline=", 10) == IDENTICAL)) {
03918 dump_flags.preinline = TRUE;
03919 cp = cp + 10;
03920 strcpy(preinline_file, cp);
03921 non_debug_ok = TRUE;
03922 }
03923 else if (EQUAL_STRS(cp, "f")) {
03924 dump_flags.fortran_out = TRUE;
03925 }
03926 else if (EQUAL_STRS(cp, "all")) {
03927 dump_flags.blk_stk = TRUE;
03928 dump_flags.bd_tbl = TRUE;
03929 dump_flags.cmd_line_tbls = TRUE;
03930 dump_flags.cn_tbl = TRUE;
03931 dump_flags.fort_out = TRUE;
03932 dump_flags.fp_tbl = TRUE;
03933 dump_flags.ftrace_info = FALSE;
03934 dump_flags.gl_tbl = TRUE;
03935 dump_flags.intrin_tbl = FALSE;
03936 dump_flags.ir1_tbl = TRUE;
03937 dump_flags.ir2_tbl = TRUE;
03938 dump_flags.ir3_tbl = FALSE;
03939 dump_flags.ir4_tbl = FALSE;
03940 dump_flags.mem_report = FALSE;
03941 dump_flags.mtrace_info = TRUE;
03942 dump_flags.name_tbls = TRUE;
03943 dump_flags.pdgcs = TRUE;
03944 dump_flags.sb_tbl = TRUE;
03945 dump_flags.scp_tbl = TRUE;
03946 dump_flags.std_err = FALSE;
03947 dump_flags.sytb = TRUE;
03948 dump_flags.typ_tbl = TRUE;
03949 dump_flags.defines = TRUE;
03950 dump_flags.abort_on_ansi = FALSE;
03951
03952
03953
03954
03955 dump_flags.src_dmp = FALSE;
03956 dump_flags.stmt_dmp = TRUE;
03957 dump_flags.pdt_dump = TRUE;
03958
03959 }
03960 else if (EQUAL_STRS(cp, "bd")) {
03961 dump_flags.bd_tbl = TRUE;
03962 }
03963 else if (EQUAL_STRS(cp, "blk")) {
03964 dump_flags.blk_stk = TRUE;
03965 }
03966 else if (EQUAL_STRS(cp, "cmd")) {
03967 dump_flags.cmd_line_tbls = TRUE;
03968 }
03969 else if (EQUAL_STRS(cp, "cn")) {
03970 dump_flags.cn_tbl = TRUE;
03971 }
03972 else if (EQUAL_STRS(cp, "defines")) {
03973 dump_flags.defines = TRUE;
03974 }
03975 else if (EQUAL_STRS(cp, "cnout")) {
03976 dump_flags.constant_bits = TRUE;
03977 }
03978 else if ((strncmp (cp, "pvp_test=", 9) == IDENTICAL)) {
03979 cp = cp + 9;
03980 dump_flags.pvp_test = atoi (cp);
03981 non_debug_ok = TRUE;
03982 }
03983 else if (EQUAL_STRS(cp, "pvp_test")) {
03984 dump_flags.pvp_test = 1;
03985 non_debug_ok = TRUE;
03986 }
03987 else if ((strncmp (cp, "file=", 5) == IDENTICAL)) {
03988 cp = cp + 5;
03989 strcpy(debug_file_name, cp);
03990 non_debug_ok = TRUE;
03991 }
03992 else if (EQUAL_STRS(cp, "fortran")) {
03993 dump_flags.fort_out = TRUE;
03994 }
03995 else if (EQUAL_STRS(cp, "fp")) {
03996 dump_flags.fp_tbl = TRUE;
03997 }
03998 else if (EQUAL_STRS(cp, "ftrace")) {
03999 dump_flags.ftrace_info = TRUE;
04000 }
04001 else if (EQUAL_STRS(cp, "gl")) {
04002 dump_flags.gl_tbl = TRUE;
04003 }
04004 else if (EQUAL_STRS(cp, "intrin")) {
04005 dump_flags.intrin_tbl = TRUE;
04006 }
04007 else if (EQUAL_STRS(cp, "ir1")) {
04008 dump_flags.ir1_tbl = TRUE;
04009 }
04010 else if (EQUAL_STRS(cp, "ir2")) {
04011 dump_flags.ir2_tbl = TRUE;
04012 }
04013 else if (EQUAL_STRS(cp, "ir3")) {
04014 dump_flags.ir3_tbl = TRUE;
04015 }
04016 else if (EQUAL_STRS(cp, "ir4")) {
04017 dump_flags.ir4_tbl = TRUE;
04018 }
04019 else if (EQUAL_STRS(cp, "mem_report")) {
04020 dump_flags.mem_report = TRUE;
04021 }
04022 else if (EQUAL_STRS(cp, "msg")) {
04023 dump_flags.msg_checking = TRUE;
04024 }
04025 else if (EQUAL_STRS(cp, "mtrace")) {
04026 dump_flags.mtrace_info = TRUE;
04027 }
04028 else if (EQUAL_STRS(cp, "names")) {
04029 dump_flags.name_tbls = TRUE;
04030 }
04031 else if (EQUAL_STRS(cp, "pdg")) {
04032 dump_flags.pdgcs = TRUE;
04033 }
04034 else if (EQUAL_STRS(cp, "pdt")) {
04035 dump_flags.pdt_dump = TRUE;
04036 }
04037 else if (EQUAL_STRS(cp, "sb")) {
04038 dump_flags.sb_tbl = TRUE;
04039 }
04040 else if (EQUAL_STRS(cp, "scp")) {
04041 dump_flags.scp_tbl = TRUE;
04042 }
04043 else if (EQUAL_STRS(cp, "src")) {
04044 dump_flags.src_dmp = TRUE;
04045 }
04046 else if (EQUAL_STRS(cp, "stderr")) {
04047 dump_flags.std_err = TRUE;
04048 }
04049 else if (EQUAL_STRS(cp, "stmt")) {
04050 dump_flags.stmt_dmp = TRUE;
04051 }
04052 else if (EQUAL_STRS(cp, "sytb")) {
04053 dump_flags.sytb = TRUE;
04054 }
04055 else if (EQUAL_STRS(cp, "typ")) {
04056 dump_flags.typ_tbl = TRUE;
04057 }
04058 else {
04059 ntr_msg_queue(0, 78, Log_Error, 0, cp, 'u', ARG_STR_ARG);
04060 }
04061 }
04062
04063 #ifndef _DEBUG
04064
04065 if (!non_debug_ok) {
04066 ntr_msg_queue(0, 877, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
04067 }
04068 #endif
04069
04070 TRACE (Func_Exit, "process_u_option", NULL);
04071
04072 return;
04073
04074 }
04075
04076
04077
04078
04079
04080
04081
04082
04083
04084
04085
04086
04087
04088
04089
04090
04091
04092
04093
04094 static void process_x_option (char *optargs)
04095
04096 {
04097 char *cp;
04098 boolean issue_warning = FALSE;
04099 token_values_type tok_type;
04100
04101
04102 TRACE (Func_Entry, "process_x_option", NULL);
04103
04104 while (*optargs != EOS) {
04105
04106 for (cp = optargs;
04107 *optargs != COMMA && *optargs != EOS;
04108 ++optargs);
04109
04110 if (*optargs != EOS) {
04111 *optargs = EOS;
04112 *optargs++;
04113 }
04114
04115 tok_type = get_dir_token_from_str(cp);
04116
04117 if (tok_type == Tok_Id) {
04118
04119
04120
04121
04122
04123 switch(*cp) {
04124 case 'a':
04125
04126 if (EQUAL_STRS(cp, "all")) {
04127 cmd_line_flags.disregard_all_directives = TRUE;
04128 cmd_line_flags.disregard_all_dirs = TRUE;
04129 cmd_line_flags.disregard_all_mics = TRUE;
04130 cmd_line_flags.disregard_all_mips = TRUE;
04131 cmd_line_flags.disregard_all_omps = TRUE;
04132 cmd_line_flags.disregard_conditional_omp = TRUE;
04133
04134 cmd_line_flags.disregard_all_openads = TRUE;
04135 }
04136 else {
04137 ntr_msg_queue(0, 78, Log_Error, 0, cp, 'x', ARG_STR_ARG);
04138 }
04139 break;
04140
04141 case 'c':
04142
04143 if (EQUAL_STRS(cp, "conditional_omp")) {
04144 cmd_line_flags.disregard_conditional_omp = TRUE;
04145 }
04146 else {
04147 PRINTMSG (0, 78, Log_Error, 0, 'x', cp);
04148 }
04149 break;
04150
04151
04152 case 'd':
04153
04154 if (EQUAL_STRS(cp, "dir")) {
04155 cmd_line_flags.disregard_all_dirs = TRUE;
04156 }
04157 else {
04158 ntr_msg_queue(0, 78, Log_Error, 0, cp, 'x', ARG_STR_ARG);
04159 }
04160 break;
04161
04162
04163 case 'm':
04164
04165 if (EQUAL_STRS(cp, "mic")) {
04166 cmd_line_flags.disregard_all_mics = TRUE;
04167 }
04168 else if (EQUAL_STRS(cp, "mpp")) {
04169 cmd_line_flags.disregard_all_mpp_cdirs = TRUE;
04170 }
04171 else if (EQUAL_STRS(cp, "mipspro")) {
04172 cmd_line_flags.disregard_all_mips = TRUE;
04173 }
04174 else {
04175 ntr_msg_queue(0, 78, Log_Error, 0, cp, 'x', ARG_STR_ARG);
04176 }
04177 break;
04178
04179
04180 case 'o':
04181
04182 if (EQUAL_STRS(cp, "omp")) {
04183 cmd_line_flags.disregard_all_omps = TRUE;
04184 cmd_line_flags.disregard_conditional_omp = TRUE;
04185 }
04186 else if (EQUAL_STRS(cp, "openad")) {
04187
04188 cmd_line_flags.disregard_all_openads = TRUE;
04189 }
04190 else {
04191 PRINTMSG (0, 78, Log_Error, 0, 'x', cp);
04192 }
04193 break;
04194
04195
04196 default:
04197 ntr_msg_queue(0, 78, Log_Error, 0, cp, 'x', ARG_STR_ARG);
04198 break;
04199 }
04200 }
04201 else if (tok_type == Tok_Unknown) {
04202 ntr_msg_queue(0, 78, Log_Error, 0, cp, 'x', ARG_STR_ARG);
04203 }
04204 else {
04205
04206 if (tok_type > Tok_Dir_Start && tok_type < Tok_Dir_End) {
04207 disregard_directive[tok_type - Tok_Dir_Start] = TRUE;
04208 }
04209 if (tok_type > Tok_Mic_Start && tok_type < Tok_Mic_End) {
04210 disregard_mics[tok_type - Tok_Mic_Start] = TRUE;
04211 }
04212 if (tok_type > Tok_SGI_Dir_Start && tok_type < Tok_SGI_Dir_End) {
04213 disregard_mips[tok_type - Tok_SGI_Dir_Start] = TRUE;
04214 }
04215 if (tok_type > Tok_Open_Mp_Dir_Start &&
04216 tok_type < Tok_Open_Mp_Dir_End) {
04217 disregard_open_mp[tok_type - Tok_Open_Mp_Dir_Start] = TRUE;
04218 }
04219
04220
04221
04222
04223
04224
04225
04226
04227
04228
04229
04230
04231 switch(tok_type) {
04232
04233
04234
04235 case Tok_Dir_Barrier :
04236 case Tok_SGI_Dir_Barrier :
04237 case Tok_Open_Mp_Dir_Barrier :
04238 disregard_directive[Tok_Dir_Barrier - Tok_Dir_Start] = TRUE;
04239 disregard_mips[Tok_SGI_Dir_Barrier - Tok_SGI_Dir_Start] = TRUE;
04240 disregard_open_mp[Tok_Open_Mp_Dir_Barrier -
04241 Tok_Open_Mp_Dir_Start] = TRUE;
04242 break;
04243
04244 case Tok_Dir_Blockable :
04245 case Tok_SGI_Dir_Blockable :
04246 disregard_directive[Tok_Dir_Blockable - Tok_Dir_Start] = TRUE;
04247 disregard_mips[Tok_SGI_Dir_Blockable - Tok_SGI_Dir_Start] = TRUE;
04248 break;
04249
04250 case Tok_Dir_Blockingsize :
04251 case Tok_SGI_Dir_Blockingsize :
04252 disregard_directive[Tok_Dir_Blockingsize - Tok_Dir_Start] = TRUE;
04253 disregard_mips[Tok_SGI_Dir_Blockingsize - Tok_SGI_Dir_Start]= TRUE;
04254 break;
04255
04256 case Tok_Dir_Concurrent :
04257 case Tok_SGI_Dir_Concurrent :
04258 disregard_directive[Tok_Dir_Concurrent - Tok_Dir_Start] = TRUE;
04259 disregard_mips[Tok_SGI_Dir_Concurrent - Tok_SGI_Dir_Start] = TRUE;
04260 break;
04261
04262
04263 case Tok_Open_Mp_Dir_Copyin :
04264 case Tok_SGI_Dir_Copyin :
04265 disregard_mips[Tok_SGI_Dir_Copyin - Tok_SGI_Dir_Start] = TRUE;
04266 break;
04267
04268 case Tok_Dir_Critical :
04269 case Tok_Open_Mp_Dir_Critical :
04270 disregard_directive[Tok_Dir_Critical - Tok_Dir_Start] = TRUE;
04271 disregard_open_mp[Tok_Open_Mp_Dir_Critical -
04272 Tok_Open_Mp_Dir_Start] = TRUE;
04273 break;
04274
04275 case Tok_Open_Mp_Dir_Distribute :
04276 case Tok_SGI_Dir_Distribute :
04277 disregard_mips[Tok_SGI_Dir_Distribute - Tok_SGI_Dir_Start] = TRUE;
04278 disregard_open_mp[Tok_Open_Mp_Dir_Distribute -
04279 Tok_Open_Mp_Dir_Start] = TRUE;
04280 break;
04281
04282 case Tok_Open_Mp_Dir_Distribute_Reshape :
04283 case Tok_SGI_Dir_Distribute_Reshape :
04284 disregard_mips[Tok_SGI_Dir_Distribute_Reshape -
04285 Tok_SGI_Dir_Start] = TRUE;
04286 disregard_open_mp[Tok_Open_Mp_Dir_Distribute_Reshape -
04287 Tok_Open_Mp_Dir_Start] = TRUE;
04288 break;
04289
04290 case Tok_Open_Mp_Dir_Do :
04291 case Tok_SGI_Dir_Do :
04292 disregard_open_mp[Tok_Open_Mp_Dir_Do -
04293 Tok_Open_Mp_Dir_Start] = TRUE;
04294 break;
04295
04296 case Tok_Dir_Dynamic :
04297 case Tok_Open_Mp_Dir_Dynamic :
04298 case Tok_SGI_Dir_Dynamic :
04299 disregard_directive[Tok_Dir_Dynamic - Tok_Dir_Start] = TRUE;
04300 disregard_mips[Tok_SGI_Dir_Dynamic - Tok_SGI_Dir_Start] = TRUE;
04301 disregard_open_mp[Tok_Open_Mp_Dir_Dynamic -
04302 Tok_Open_Mp_Dir_Start] = TRUE;
04303 break;
04304
04305 case Tok_Dir_Endcritical :
04306 case Tok_Open_Mp_Dir_Endcritical :
04307 disregard_directive[Tok_Dir_Endcritical - Tok_Dir_Start] = TRUE;
04308 disregard_open_mp[Tok_Open_Mp_Dir_Endcritical -
04309 Tok_Open_Mp_Dir_Start] = TRUE;
04310 break;
04311
04312 case Tok_Dir_Endmaster :
04313 case Tok_Open_Mp_Dir_Endmaster :
04314 disregard_directive[Tok_Dir_Endmaster - Tok_Dir_Start] = TRUE;
04315 disregard_open_mp[Tok_Open_Mp_Dir_Endmaster -
04316 Tok_Open_Mp_Dir_Start] = TRUE;
04317 break;
04318
04319 case Tok_Open_Mp_Dir_Endparallel :
04320 case Tok_SGI_Dir_Endparallel :
04321 case Tok_Mic_End_Parallel :
04322 disregard_mics[Tok_Mic_End_Parallel - Tok_Mic_Start] = TRUE;
04323 disregard_mips[Tok_SGI_Dir_Endparallel - Tok_SGI_Dir_Start] = TRUE;
04324 disregard_open_mp[Tok_Open_Mp_Dir_Endparallel -
04325 Tok_Open_Mp_Dir_Start] = TRUE;
04326 break;
04327
04328 case Tok_Open_Mp_Dir_Flush :
04329 case Tok_SGI_Dir_Flush :
04330 disregard_mips[Tok_SGI_Dir_Flush - Tok_SGI_Dir_Start] = TRUE;
04331 disregard_open_mp[Tok_Open_Mp_Dir_Flush -
04332 Tok_Open_Mp_Dir_Start] = TRUE;
04333 break;
04334
04335 case Tok_Dir_Inline :
04336 case Tok_SGI_Dir_Inline :
04337 disregard_directive[Tok_Dir_Inline - Tok_Dir_Start] = TRUE;
04338 disregard_mips[Tok_SGI_Dir_Inline - Tok_SGI_Dir_Start] = TRUE;
04339 break;
04340
04341 case Tok_Dir_Interchange :
04342 case Tok_SGI_Dir_Interchange :
04343 disregard_directive[Tok_Dir_Interchange - Tok_Dir_Start] = TRUE;
04344 disregard_mips[Tok_SGI_Dir_Interchange - Tok_SGI_Dir_Start] = TRUE;
04345 break;
04346
04347 case Tok_Dir_Master :
04348 case Tok_Open_Mp_Dir_Master :
04349 disregard_directive[tok_type - Tok_Dir_Start] = TRUE;
04350 disregard_open_mp[tok_type - Tok_Open_Mp_Dir_Start] = TRUE;
04351 break;
04352
04353 case Tok_Dir_Maxcpus :
04354 case Tok_Mic_Maxcpus :
04355 disregard_directive[Tok_Dir_Maxcpus - Tok_Dir_Start] = TRUE;
04356 break;
04357
04358 case Tok_Dir_Noblocking :
04359 case Tok_SGI_Dir_Noblocking :
04360 disregard_directive[Tok_Dir_Noblocking - Tok_Dir_Start] = TRUE;
04361 disregard_mips[Tok_SGI_Dir_Noblocking - Tok_SGI_Dir_Start] = TRUE;
04362 break;
04363
04364 case Tok_Dir_Noinline :
04365 case Tok_SGI_Dir_Noinline :
04366 disregard_directive[Tok_Dir_Noinline - Tok_Dir_Start] = TRUE;
04367 disregard_mips[Tok_SGI_Dir_Noinline - Tok_SGI_Dir_Start] = TRUE;
04368 break;
04369
04370 case Tok_Dir_Nointerchange :
04371 case Tok_SGI_Dir_Nointerchange :
04372 disregard_directive[Tok_Dir_Nointerchange - Tok_Dir_Start] = TRUE;
04373 disregard_mips[Tok_SGI_Dir_Nointerchange -
04374 Tok_SGI_Dir_Start] = TRUE;
04375 break;
04376
04377 case Tok_Dir_Norecurrence :
04378 case Tok_SGI_Dir_Norecurrence :
04379 disregard_directive[Tok_SGI_Dir_Norecurrence - Tok_Dir_Start]= TRUE;
04380 break;
04381
04382
04383 case Tok_SGI_Dir_Ordered :
04384 case Tok_Open_Mp_Dir_Ordered :
04385 disregard_mips[Tok_SGI_Dir_Ordered - Tok_SGI_Dir_Start] = TRUE;
04386 disregard_open_mp[Tok_Open_Mp_Dir_Ordered -
04387 Tok_Open_Mp_Dir_Start] = TRUE;
04388 break;
04389
04390 case Tok_SGI_Dir_Page_Place :
04391 case Tok_Open_Mp_Dir_Page_Place :
04392 disregard_mips[Tok_SGI_Dir_Page_Place - Tok_SGI_Dir_Start] = TRUE;
04393 disregard_open_mp[Tok_Open_Mp_Dir_Page_Place -
04394 Tok_Open_Mp_Dir_Start] = TRUE;
04395 break;
04396
04397 case Tok_Mic_Parallel :
04398 case Tok_SGI_Dir_Parallel :
04399 case Tok_Open_Mp_Dir_Parallel :
04400 disregard_mics[Tok_Mic_Parallel - Tok_Mic_Start] = TRUE;
04401 disregard_mips[Tok_SGI_Dir_Parallel - Tok_SGI_Dir_Start] = TRUE;
04402 disregard_open_mp[Tok_Open_Mp_Dir_Parallel -
04403 Tok_Open_Mp_Dir_Start] = TRUE;
04404 break;
04405
04406 case Tok_SGI_Dir_Paralleldo :
04407 case Tok_Open_Mp_Dir_Paralleldo :
04408 disregard_mips[Tok_SGI_Dir_Paralleldo - Tok_SGI_Dir_Start] = TRUE;
04409 disregard_open_mp[Tok_Open_Mp_Dir_Paralleldo -
04410 Tok_Open_Mp_Dir_Start] = TRUE;
04411 break;
04412
04413 case Tok_Open_Mp_Dir_Parallelworkshare :
04414 disregard_open_mp[tok_type - Tok_Open_Mp_Dir_Start] = TRUE;
04415 break;
04416
04417 case Tok_Mic_Permutation :
04418 case Tok_SGI_Dir_Permutation :
04419 disregard_mics[Tok_Mic_Permutation - Tok_Mic_Start] = TRUE;
04420 break;
04421
04422 case Tok_SGI_Dir_Redistribute :
04423 case Tok_Open_Mp_Dir_Redistribute :
04424 disregard_mips[Tok_SGI_Dir_Redistribute - Tok_SGI_Dir_Start]= TRUE;
04425 disregard_open_mp[Tok_Open_Mp_Dir_Redistribute -
04426 Tok_Open_Mp_Dir_Start] = TRUE;
04427 break;
04428
04429 case Tok_SGI_Dir_Section :
04430 case Tok_Open_Mp_Dir_Section :
04431 disregard_mips[Tok_SGI_Dir_Section - Tok_SGI_Dir_Start] = TRUE;
04432 disregard_open_mp[Tok_Open_Mp_Dir_Section -
04433 Tok_Open_Mp_Dir_Start] = TRUE;
04434 break;
04435
04436 case Tok_Dir_Shared :
04437 case Tok_Open_Mp_Dir_Shared :
04438 case Tok_SGI_Dir_Shared :
04439 disregard_directive[Tok_Dir_Shared - Tok_Dir_Start] = TRUE;
04440 break;
04441
04442 case Tok_Dir_Single :
04443 case Tok_Open_Mp_Dir_Single :
04444 disregard_open_mp[Tok_Open_Mp_Dir_Single -
04445 Tok_Open_Mp_Dir_Start] = TRUE;
04446 break;
04447
04448 case Tok_Open_Mp_Dir_Workshare :
04449 disregard_open_mp[Tok_Open_Mp_Dir_Workshare -
04450 Tok_Open_Mp_Dir_Start] = TRUE;
04451 break;
04452
04453 case Tok_Dir_Taskcommon :
04454 case Tok_Mic_Taskcommon :
04455 disregard_directive[Tok_Dir_Taskcommon - Tok_Dir_Start] = TRUE;
04456 disregard_mics[Tok_Mic_Taskcommon - Tok_Mic_Start] = TRUE;
04457 break;
04458
04459 case Tok_Dir_Unroll :
04460 case Tok_SGI_Dir_Unroll :
04461 disregard_directive[Tok_Dir_Unroll - Tok_Dir_Start] = TRUE;
04462 disregard_mips[Tok_SGI_Dir_Unroll - Tok_SGI_Dir_Start] = TRUE;
04463 break;
04464
04465 case Tok_Dir_Vector :
04466 case Tok_SGI_Dir_Vector :
04467 disregard_directive[Tok_Dir_Vector - Tok_Dir_Start] = TRUE;
04468 break;
04469
04470
04471
04472 case Tok_Dir_Align :
04473 case Tok_Dir_Auxiliary :
04474 case Tok_Dir_Bl :
04475 case Tok_Dir_Bounds :
04476 case Tok_Dir_Cache_Align :
04477 case Tok_Dir_Cache_Bypass :
04478 case Tok_Dir_Cache_Noalloc :
04479 case Tok_Dir_Common :
04480 case Tok_Dir_Copy_Assumed_Shape :
04481 case Tok_Dir_Eject :
04482 case Tok_Dir_Flow :
04483 case Tok_Dir_Fixed :
04484 case Tok_Dir_Free :
04485 case Tok_Dir_Id :
04486 case Tok_Dir_Ignore_TKR :
04487 case Tok_Dir_Inline_Always :
04488 case Tok_Dir_Inline_Never :
04489 case Tok_Dir_Ivdep :
04490 case Tok_Dir_List :
04491 case Tok_Dir_Mark :
04492 case Tok_Dir_Modinline :
04493 case Tok_Dir_Name :
04494 case Tok_Dir_Nextscalar :
04495 case Tok_Dir_Nobl :
04496 case Tok_Dir_Nobounds :
04497 case Tok_Dir_Noflow :
04498 case Tok_Dir_Nolist :
04499 case Tok_Dir_Nomark :
04500 case Tok_Dir_Nomodinline :
04501 case Tok_Dir_Nopattern :
04502 case Tok_Dir_Nosideeffects :
04503 case Tok_Dir_Nosplit :
04504 case Tok_Dir_Nostream :
04505 case Tok_Dir_Notask :
04506 case Tok_Dir_Nounroll :
04507 case Tok_Dir_Novector :
04508 case Tok_Dir_Novsearch :
04509 case Tok_Dir_Pattern :
04510 case Tok_Dir_Preferstream :
04511 case Tok_Dir_Prefertask :
04512 case Tok_Dir_Prefervector :
04513 case Tok_Dir_Recurrence :
04514 case Tok_Dir_Shortloop :
04515 case Tok_Dir_Split :
04516 case Tok_Dir_Stack :
04517 case Tok_Dir_Stream :
04518 case Tok_Dir_Suppress :
04519 case Tok_Dir_Symmetric :
04520 case Tok_Dir_System_Module :
04521 case Tok_Dir_Task :
04522 case Tok_Dir_Uses_Eregs :
04523 case Tok_Dir_Vfunction :
04524 case Tok_Dir_Vsearch :
04525 break;
04526
04527
04528 case Tok_Mic_Case :
04529 case Tok_Mic_End_Case :
04530 case Tok_Mic_Cncall :
04531 case Tok_Mic_Do_All :
04532 case Tok_Mic_Do_Parallel :
04533 case Tok_Mic_End_Do :
04534 case Tok_Mic_Guard :
04535 case Tok_Mic_End_Guard :
04536 case Tok_Mic_Numcpus :
04537 case Tok_Mic_Wait :
04538 case Tok_Mic_Send :
04539 break;
04540
04541
04542
04543
04544 case Tok_Open_Mp_Dir_Atomic :
04545 case Tok_Open_Mp_Dir_Enddo :
04546 case Tok_Open_Mp_Dir_Endordered :
04547 case Tok_Open_Mp_Dir_Endparalleldo :
04548 case Tok_Open_Mp_Dir_Endparallelsections :
04549 case Tok_Open_Mp_Dir_Endparallelworkshare :
04550 case Tok_Open_Mp_Dir_Endsections :
04551 case Tok_Open_Mp_Dir_Endsingle :
04552 case Tok_Open_Mp_Dir_Endworkshare :
04553 case Tok_Open_Mp_Dir_Parallelsections :
04554 case Tok_Open_Mp_Dir_Sections :
04555 case Tok_Open_Mp_Dir_Threadprivate :
04556 break;
04557
04558
04559
04560
04561 case Tok_OpenAD_Dir_XXX:
04562 case Tok_OpenAD_Dir_Dependent:
04563 case Tok_OpenAD_Dir_Independent:
04564 case Tok_OpenAD_Dir_Simple:
04565 case Tok_OpenAD_Dir_EndSimple:
04566 break;
04567
04568
04569
04570
04571 case Tok_SGI_Dir_Aggressiveinner :
04572 case Tok_SGI_Dir_Align_Symbol :
04573 case Tok_SGI_Dir_Assert :
04574 case Tok_SGI_Dir_Chunk :
04575 case Tok_SGI_Dir_Criticalsection :
04576 case Tok_SGI_Dir_Doacross :
04577 case Tok_SGI_Dir_Endcriticalsection :
04578 case Tok_SGI_Dir_Endpsections :
04579 case Tok_SGI_Dir_Endpsection :
04580 case Tok_SGI_Dir_Endpdo :
04581 case Tok_SGI_Dir_Endsingleprocess :
04582 case Tok_SGI_Dir_Fill_Symbol :
04583 case Tok_SGI_Dir_Fission :
04584 case Tok_SGI_Dir_Fissionable :
04585 case Tok_SGI_Dir_Fusable :
04586 case Tok_SGI_Dir_Fuse :
04587 case Tok_SGI_Dir_Ipa :
04588 case Tok_SGI_Dir_Limit :
04589 case Tok_SGI_Dir_Minconcurrent :
04590 case Tok_SGI_Dir_Mp_Schedtype :
04591 case Tok_SGI_Dir_Noconcurrentize :
04592 case Tok_SGI_Dir_Nofission :
04593 case Tok_SGI_Dir_Nofusion :
04594 case Tok_SGI_Dir_Noipa :
04595 case Tok_SGI_Dir_Opaque :
04596 case Tok_SGI_Dir_Optional :
04597 case Tok_SGI_Dir_Pdo :
04598 case Tok_SGI_Dir_Prefetch_Manual :
04599 case Tok_SGI_Dir_Prefetch_Ref :
04600 case Tok_SGI_Dir_Prefetch :
04601 case Tok_SGI_Dir_Prefetch_Ref_Disable :
04602 case Tok_SGI_Dir_Psection :
04603 case Tok_SGI_Dir_Psections :
04604 case Tok_SGI_Dir_Purpleconditional :
04605 case Tok_SGI_Dir_Purpleunconditional :
04606 case Tok_SGI_Dir_Regionbegin :
04607 case Tok_SGI_Dir_Regionend :
04608 case Tok_SGI_Dir_Section_Gp :
04609 case Tok_SGI_Dir_Section_Non_Gp :
04610 case Tok_SGI_Dir_Singleprocess :
04611 break;
04612
04613
04614
04615 case Tok_Dir_Block :
04616 case Tok_Dir_Regfile :
04617 case Tok_Dir_Semextern :
04618 case Tok_Dir_Shortsequence :
04619 case Tok_Dir_Static :
04620 case Tok_Dir_Taskhead :
04621 issue_warning = TRUE;
04622 break;
04623
04624
04625
04626 case Tok_Mic_Continue :
04627 issue_warning = TRUE;
04628
04629
04630
04631 case Tok_Dir_Atomicupdate :
04632 case Tok_Dir_Nobarrier :
04633 issue_warning = TRUE;
04634 break;
04635
04636 }
04637
04638 if (issue_warning) {
04639 PRINTMSG (0, 604, Log_Warning, 0, 'x', cp);
04640 issue_warning = FALSE;
04641 }
04642 }
04643 }
04644
04645 TRACE (Func_Exit, "process_x_option", NULL);
04646
04647 return;
04648
04649 }
04650
04651
04652
04653
04654
04655
04656
04657
04658
04659
04660
04661
04662
04663
04664
04665
04666
04667
04668 static void process_M_option (char *optargs)
04669
04670 {
04671 char *cp;
04672 long msg_num;
04673 boolean suppress;
04674 long *table_ptr;
04675
04676
04677 TRACE (Func_Entry, "process_M_option", NULL);
04678
04679 while (*optargs != EOS) {
04680
04681 for (cp = optargs;
04682 *optargs != BLANK && *optargs != COMMA && *optargs != EOS;
04683 ++optargs);
04684
04685 if (*optargs != EOS) {
04686 *optargs = EOS;
04687 *optargs++;
04688 }
04689
04690 table_ptr = (long *) message_suppress_tbl;
04691 suppress = TRUE;
04692
04693 if (*cp == 'E') {
04694 *cp++;
04695 suppress = FALSE;
04696 table_ptr = (long *) message_error_tbl;
04697 }
04698 else if (*cp == 'W') {
04699 *cp++;
04700 suppress = FALSE;
04701 table_ptr = (long *) message_warning_tbl;
04702 }
04703 else if (*cp < '0' || *cp > '9') {
04704 ntr_msg_queue(0, 78, Log_Error, 0, cp, 'M', ARG_STR_ARG);
04705 }
04706
04707 msg_num = atoi(cp);
04708
04709 if (msg_num < 0 || msg_num > (MAX_MSG_SIZE*HOST_BITS_PER_WORD) - 1) {
04710 ntr_msg_queue(0, 78, Log_Error, 0, cp, 'M', ARG_STR_ARG);
04711 }
04712 else {
04713
04714 if (suppress && !GET_MESSAGE_TBL(message_suppress_tbl, msg_num)) {
04715 cmd_line_flags.num_msgs_suppressed++;
04716 }
04717
04718 SET_MESSAGE_TBL(table_ptr, msg_num);
04719 }
04720 }
04721
04722 TRACE (Func_Exit, "process_M_option", NULL);
04723
04724 return;
04725
04726 }
04727
04728
04729
04730
04731
04732
04733
04734
04735
04736
04737
04738
04739
04740
04741
04742
04743
04744
04745 static void process_Y_option (char *optargs)
04746
04747 {
04748 int ch;
04749
04750
04751 TRACE (Func_Entry, "process_Y_option", NULL);
04752
04753
04754 while (ch = *optargs++) {
04755 #ifdef _TARGET32
04756 ccg_dump_flags = ccg_dump_flags | (1 << ((ch - 'A') & 0x1F));
04757 #else
04758 ccg_dump_flags = ccg_dump_flags | (1 << (ch - 'A'));
04759 #endif
04760 }
04761
04762
04763 TRACE (Func_Exit, "process_Y_option", NULL);
04764
04765 return;
04766
04767 }
04768
04769
04770
04771
04772
04773
04774
04775
04776
04777
04778
04779
04780
04781
04782
04783
04784
04785
04786
04787 static void set_prog_file_names (char *argv[])
04788
04789 {
04790 extern char *optarg;
04791 extern int optind;
04792
04793 int fp_idx;
04794 int idx;
04795 int length;
04796 char *stp;
04797
04798
04799 TRACE (Func_Entry, "set_prog_file_names", NULL);
04800
04801
04802
04803
04804 optarg = argv[optind];
04805
04806 if (optarg == NULL) {
04807 src_file[0] = EOS;
04808
04809
04810
04811 if (binary_output && bin_file[0] == EOS) {
04812
04813
04814
04815 ntr_msg_queue(0, 80, Log_Error, 0, "binary", 0, STR_ARG);
04816 binary_output = FALSE;
04817 }
04818
04819
04820
04821 if (assembly_output && assembly_file[0] == EOS) {
04822
04823
04824
04825 ntr_msg_queue(0, 80, Log_Error, 0, "assembly", 0, STR_ARG);
04826 assembly_output = FALSE;
04827 }
04828
04829 if (on_off_flags.assembly_listing_file) {
04830 strcpy(assembly_listing_file, "stdout");
04831 }
04832
04833 strcpy(debug_file_name, "stderr");
04834 }
04835 else {
04836 strncpy (src_file, optarg, MAX_FILE_NAME_SIZE);
04837 src_file[MAX_FILE_NAME_SIZE-1] = EOS;
04838
04839
04840
04841 if (binary_output && bin_file[0] == EOS) {
04842 MAKE_DEFAULT_NAME (bin_file, src_file, "o");
04843 }
04844
04845
04846
04847 if (assembly_output && assembly_file[0] == EOS) {
04848 MAKE_DEFAULT_NAME (assembly_file, src_file, "s");
04849 }
04850
04851 if (on_off_flags.assembly_listing_file) {
04852 MAKE_DEFAULT_NAME (assembly_listing_file, src_file, "L");
04853 }
04854
04855
04856
04857
04858
04859
04860
04861 if (debug_file_name[0] == NULL_CHAR) {
04862 MAKE_DEFAULT_NAME (debug_file_name, src_file, "l");
04863 }
04864
04865 if (! set_source_form_option) {
04866 stp = strrchr (src_file, DOT);
04867
04868 if (stp != NULL) {
04869
04870 if (EQUAL_STRS(stp, ".f") ||
04871 EQUAL_STRS(stp, ".F")) {
04872 cmd_line_flags.src_form = Fixed_Form;
04873 source_form = Fixed_Form;
04874 }
04875 else if (EQUAL_STRS(stp, ".f90") ||
04876 EQUAL_STRS(stp, ".caf") ||
04877 EQUAL_STRS(stp, ".F90")) {
04878 cmd_line_flags.src_form = Free_Form;
04879 source_form = Free_Form;
04880 }
04881 }
04882 }
04883
04884 # if defined(_FRONTEND_CONDITIONAL_COMP)
04885 if (! no_preprocessing) {
04886
04887 stp = strrchr (src_file, DOT);
04888
04889 if (stp != NULL) {
04890
04891 if (EQUAL_STRS(stp, ".F") ||
04892 EQUAL_STRS(stp, ".F90")) {
04893
04894 on_off_flags.preprocess = TRUE;
04895 }
04896 }
04897 }
04898 # endif
04899 }
04900
04901
04902
04903
04904 fp_idx = inline_path_idx;
04905
04906 while (fp_idx != NULL_IDX) {
04907
04908 if (strcmp(bin_file, FP_NAME_PTR(fp_idx)) == 0) {
04909
04910
04911
04912
04913
04914 PRINTMSG(0, 1252, Log_Error, 0, bin_file, FP_NAME_PTR(fp_idx));
04915 }
04916 fp_idx = FP_NEXT_FILE_IDX(fp_idx);
04917 }
04918
04919 if (cif_flags != 0 && cif_name[0] == '\0') {
04920 MAKE_DEFAULT_NAME (cif_name, src_file, "T");
04921 }
04922
04923 if (on_off_flags.preprocess_only || on_off_flags.save_dot_i) {
04924 MAKE_DEFAULT_NAME (dot_i_file, src_file, "i");
04925 }
04926
04927
04928
04929
04930 TBL_REALLOC_CK(file_path_tbl, 1);
04931 CLEAR_TBL_NTRY(file_path_tbl, file_path_tbl_idx);
04932 FP_NAME_LEN(file_path_tbl_idx) = 2;
04933 FP_NAME_IDX(file_path_tbl_idx) = str_pool_idx + 1;
04934 FP_SRCH_THE_FILE(file_path_tbl_idx) = TRUE;
04935 length = WORD_LEN(2);
04936
04937 TBL_REALLOC_CK(str_pool, length);
04938
04939 for (idx = FP_NAME_IDX(file_path_tbl_idx); idx <= str_pool_idx; idx++) {
04940 str_pool[idx].name_long = 0;
04941 }
04942
04943 strcpy(FP_NAME_PTR(file_path_tbl_idx), "./");
04944
04945 if (module_path_idx != NULL_IDX) {
04946 idx = module_path_idx;
04947
04948 while (FP_NEXT_FILE_IDX(idx) != NULL_IDX) {
04949 idx = FP_NEXT_FILE_IDX(idx);
04950 }
04951 FP_NEXT_FILE_IDX(idx) = file_path_tbl_idx;
04952 }
04953 else {
04954 module_path_idx = file_path_tbl_idx;
04955 }
04956
04957 set_system_module_path();
04958
04959 TRACE (Func_Exit, "set_prog_file_names", NULL);
04960
04961 return;
04962
04963 }
04964
04965
04966
04967
04968
04969
04970
04971
04972
04973
04974
04975
04976
04977
04978
04979
04980
04981
04982
04983 static void dump_help_screen(void)
04984 {
04985 int i;
04986 char *info_str[] = {
04987 "The following options are available in a compiler with -u: ",
04988 " ",
04989 "abort_ansi Abort compilation after first ANSI msg.",
04990 "cray_compatible Sgi turns s_default64 on, int1,2 off.",
04991 "f Unimplemented - controls fortran output.",
04992 "dsm Set by mongoose driver - not a user option.",
04993 "fmm Controls f-- prototype.",
04994 "fmm1 Controls f-- prototype.",
04995 "fmm2 Controls f-- prototype.",
04996 "mod_version Prints each module version number being read in",
04997 "mp Allow recognition of the SGI directives.",
04998 "no_dim_pad Do not pad out missing dimensions.",
04999 "no_mod_output Do not do module output.",
05000 "open_mp Allow recognition of the open mp directives.",
05001 "pack_half_word Turn on component packing for sdefault32",
05002 "preinline= Create an inline template for this file.",
05003 "pvp_test Used for meta development.",
05004 "show Show input command line to frontend.",
05005 " ",
05006 "The following options are available in a debug compiler with -u:",
05007 " ",
05008 "all Dump all tables. Do not do any tracing.",
05009 "bd Dump the bounds table.",
05010 "blk Dump the Block Stack.",
05011 "cmd Dump the commandline table.",
05012 "cn Dump the Constant table.",
05013 "defines Dump the build definitions.",
05014 "file= Specify the name of the debug output file.",
05015 "fortran Dump the output IR in a Fortran format.",
05016 "fp Dump the File Path table.",
05017 "ftrace Activate the function trace.",
05018 "gl Dump the Global Line table.",
05019 "intrin Dump the Intrinsic table.",
05020 "ir1 Dump the IR after Pass 1.",
05021 "ir2 Dump the IR after Pass 2.",
05022 "ir3 Dump the IR after inlining.",
05023 "ir4 Dump the IR after swapping dimensions.",
05024 "mem_report Provide a report of front-end memory usage.",
05025 "msg Issue an abort for all zero line numbers.",
05026 "mtrace Trace front-end memory usage.",
05027 "names Dump the local, global and hidden name tables.",
05028 "pdg Dump all calls to the PGDCS interface.",
05029 "pdt Dump PDT info while searching for modules.",
05030 "sb Dump the Storage Block table.",
05031 "scp Dump the scope table.",
05032 "src Dump whole source program.",
05033 "stderr Output msgs to stderr rather than ordering.",
05034 "stmt Dump each statement.",
05035 "sytb Dump the symbol table.",
05036 "typ Dump the Type table.",
05037 "cnout Dump constants as binary to stdout.",
05038 "DONE" };
05039
05040 TRACE (Func_Entry, "dump_help_screen", NULL);
05041
05042 i = 0;
05043
05044 while (strcmp(info_str[i],"DONE")) fprintf(stderr, "%s\n", info_str[i++]);
05045
05046 TRACE (Func_Exit, "dump_help_screen", NULL);
05047
05048 return;
05049
05050 }
05051
05052
05053
05054
05055
05056
05057
05058
05059
05060
05061
05062
05063
05064
05065
05066
05067
05068
05069
05070
05071 static void add_to_fp_table(char *optargs,
05072 int *start_idx,
05073 int option)
05074
05075 {
05076 int fp_idx;
05077 int length;
05078 char path_name[MAX_FILE_NAME_SIZE];
05079
05080
05081 TRACE (Func_Entry, "add_to_fp_table", NULL);
05082
05083 TBL_REALLOC_CK(file_path_tbl, 1);
05084 CLEAR_TBL_NTRY(file_path_tbl, file_path_tbl_idx);
05085
05086 if (*start_idx == NULL_IDX) {
05087 *start_idx = file_path_tbl_idx;
05088 }
05089 else {
05090 fp_idx = *start_idx;
05091
05092
05093
05094 while (FP_NEXT_FILE_IDX(fp_idx) != NULL_IDX) {
05095 fp_idx = FP_NEXT_FILE_IDX(fp_idx);
05096 }
05097 FP_NEXT_FILE_IDX(fp_idx) = file_path_tbl_idx;
05098 }
05099
05100 FP_NAME_IDX(file_path_tbl_idx) = str_pool_idx + 1;
05101 length = strlen(optargs);
05102
05103 if (option == 'p' || option == 'O') {
05104 FP_SRCH_THE_FILE(file_path_tbl_idx) = TRUE;
05105 }
05106 else {
05107
05108 FP_CLASS(file_path_tbl_idx) = Include_Fp;
05109
05110 if (optargs[0] != SLASH)
05111
05112 {
05113
05114
05115 getcwd (path_name, MAX_FILE_NAME_SIZE);
05116 length += strlen(path_name) + 1;
05117 }
05118 }
05119
05120 FP_NAME_LEN(file_path_tbl_idx) = length;
05121
05122 TBL_REALLOC_CK(str_pool, WORD_LEN(length));
05123
05124 str_pool[str_pool_idx].name_long = 0;
05125
05126 if (option == 'p' || option == 'O' || optargs[0] == SLASH)
05127 {
05128 strcpy(FP_NAME_PTR(file_path_tbl_idx), optargs);
05129 }
05130 else {
05131 strcpy(FP_NAME_PTR(file_path_tbl_idx), path_name);
05132 strcat(FP_NAME_PTR(file_path_tbl_idx), "/");
05133 strcat(FP_NAME_PTR(file_path_tbl_idx), optargs);
05134 }
05135
05136 TRACE (Func_Exit, "add_to_fp_table", NULL);
05137
05138 return;
05139
05140 }
05141
05142
05143
05144
05145
05146
05147
05148
05149
05150
05151
05152
05153
05154
05155
05156
05157
05158 static void process_P_option (char *optargs)
05159
05160 {
05161 # if defined(_ACCEPT_CMD_P)
05162 int ch;
05163 char err_str[2];
05164 # endif
05165
05166
05167 TRACE (Func_Entry, "process_P_option", NULL);
05168
05169 # if defined(_ACCEPT_CMD_P)
05170 while (ch = *optargs++) {
05171
05172 switch (ch) {
05173 case 'l':
05174 cmd_line_flags.large_pic_model = TRUE;
05175 break;
05176
05177 case 's':
05178 cmd_line_flags.small_pic_model = TRUE;
05179 break;
05180
05181 default:
05182 err_str[0] = ch;
05183 err_str[1] = EOS;
05184
05185
05186
05187 ntr_msg_queue(0, 78, Log_Error, 0, err_str, 'P', ARG_STR_ARG);
05188 break;
05189 }
05190 }
05191 # else
05192 ntr_msg_queue(0, 797, Log_Warning, 0, (char *) NULL, 'P' ,ARG_ARG);
05193 # endif
05194
05195 TRACE (Func_Exit, "process_P_option", NULL);
05196
05197 return;
05198
05199 }
05200
05201
05202
05203
05204
05205
05206
05207
05208
05209
05210
05211
05212
05213
05214
05215
05216
05217 static void process_a_option(char *optargs)
05218
05219 {
05220 char *cp;
05221
05222 # if defined(_ACCEPT_CMD_a_pad)
05223 int pad_amount;
05224 # endif
05225
05226
05227 TRACE (Func_Entry, "process_a_option", NULL);
05228
05229 while (*optargs != EOS) {
05230
05231 for (cp = optargs;
05232 *optargs != BLANK && *optargs != COMMA && *optargs != EOS;
05233 ++optargs) {
05234 }
05235
05236 if (*optargs != EOS) {
05237 *optargs = EOS;
05238 *optargs++;
05239 }
05240
05241 # if 0
05242 if (EQUAL_STRS(cp, "lign8")) {
05243
05244 # if defined(_ACCEPT_CMD_align)
05245 cmd_line_flags.align8 = TRUE;
05246 # else
05247 ntr_msg_queue(0, 744, Log_Warning, 0, "align8", 'a', ARG_STR_ARG);
05248 # endif
05249 }
05250 else if (EQUAL_STRS(cp, "lign16")) {
05251
05252 # if defined(_ACCEPT_CMD_align)
05253 cmd_line_flags.align16 = TRUE;
05254 # else
05255 ntr_msg_queue(0, 744, Log_Warning, 0, "align16", 'a', ARG_STR_ARG);
05256 # endif
05257 }
05258 # endif
05259 if (EQUAL_STRS(cp, "lign32")) {
05260
05261 # if defined(_ACCEPT_CMD_align)
05262 cmd_line_flags.align32 = TRUE;
05263 # else
05264 ntr_msg_queue(0, 744, Log_Warning, 0, "align32", 'a', ARG_STR_ARG);
05265 # endif
05266 }
05267 else if (EQUAL_STRS(cp, "lign64")) {
05268
05269 # if defined(_ACCEPT_CMD_align)
05270 cmd_line_flags.align64 = TRUE;
05271 cmd_line_flags.dalign = TRUE;
05272 # else
05273 ntr_msg_queue(0, 744, Log_Warning, 0, "align64", 'a', ARG_STR_ARG);
05274 # endif
05275 }
05276 else if (EQUAL_STRS(cp, "dalign")) {
05277
05278 # if defined(_ACCEPT_CMD_a_dalign)
05279 cmd_line_flags.dalign = TRUE;
05280 # else
05281 ntr_msg_queue(0, 744, Log_Warning, 0, "dalign", 'a', ARG_STR_ARG);
05282 # endif
05283 }
05284 else if (EQUAL_STRS(cp, "static_threadprivate")) {
05285
05286 # if defined(_ACCEPT_CMD_a_static_threadprivate)
05287 cmd_line_flags.static_threadprivate = TRUE;
05288 # else
05289 ntr_msg_queue(0, 744, Log_Warning, 0, "static_threadprivate",
05290 'a', ARG_STR_ARG);
05291 # endif
05292 }
05293 else if (EQUAL_STRS(cp, "taskcommon")) {
05294
05295 # if !defined(_TASK_COMMON_EXTENSION)
05296 ntr_msg_queue(0, 744, Log_Warning, 0,
05297 "taskcommon", 'a', ARG_STR_ARG);
05298 # else
05299 cmd_line_flags.taskcommon = TRUE;
05300 # endif
05301 }
05302 else if (strncmp(cp, "pad", 3) == 0) {
05303
05304 # if defined(_ACCEPT_CMD_a_pad)
05305 cp +=3 ;
05306
05307 if (*cp != EOS) {
05308 pad_amount = atoi(cp);
05309
05310 if (pad_amount <= 0 || pad_amount >= 4096) {
05311 ntr_msg_queue(0, 1251, Log_Error, 0,
05312 (char *) NULL, pad_amount, ARG_ARG);
05313 }
05314 }
05315 else {
05316 pad_amount = 0;
05317 }
05318
05319 cmd_line_flags.pad = TRUE;
05320 cmd_line_flags.pad_amount = pad_amount;
05321 # else
05322 ntr_msg_queue(0, 744, Log_Warning, 0, "pad", 'a', ARG_STR_ARG);
05323 # endif
05324 }
05325 else {
05326 ntr_msg_queue(0, 78, Log_Error, 0, cp, 'a', ARG_STR_ARG);
05327 }
05328
05329 }
05330
05331
05332 TRACE (Func_Exit, "process_a_option", NULL);
05333
05334 return;
05335
05336 }
05337
05338
05339
05340
05341
05342
05343
05344
05345
05346
05347
05348
05349
05350
05351
05352
05353
05354 static void process_A_option(char *optargs)
05355
05356 {
05357 boolean found_one;
05358 int fp_idx;
05359 int idx;
05360 int length;
05361 char *module_name;
05362 int start_idx;
05363 char *str_ptr;
05364
05365
05366 TRACE (Func_Entry, "process_A_option", NULL);
05367
05368 start_idx = file_path_tbl_idx + 1;
05369 found_one = FALSE;
05370
05371 while (*optargs != EOS) {
05372
05373 for (module_name = optargs;
05374 *optargs != BLANK && *optargs != COMMA && *optargs != EOS;
05375 ++optargs);
05376
05377 if (*optargs != EOS) {
05378 *optargs = EOS;
05379 *optargs++;
05380 }
05381
05382 if (found_one) {
05383 FP_NEXT_FILE_IDX(file_path_tbl_idx) = file_path_tbl_idx + 1;
05384 }
05385
05386 TBL_REALLOC_CK(file_path_tbl, 1);
05387 CLEAR_TBL_NTRY(file_path_tbl, file_path_tbl_idx);
05388
05389 found_one = TRUE;
05390 FP_NAME_IDX(file_path_tbl_idx) = str_pool_idx + 1;
05391 length = strlen(module_name);
05392 FP_CLASS(file_path_tbl_idx) = Unknown_Fp;
05393 FP_NAME_LEN(file_path_tbl_idx) = length;
05394
05395 TBL_REALLOC_CK(str_pool, WORD_LEN(length));
05396
05397 str_pool[str_pool_idx].name_long = 0;
05398
05399 str_ptr = &str_pool[FP_NAME_IDX(file_path_tbl_idx)].name_char;
05400
05401 for (idx = 0; idx < length; idx++) {
05402 str_ptr[idx] = toupper(module_name[idx]);
05403 }
05404 }
05405
05406 if (found_one) {
05407
05408 if (cmd_line_flags.implicit_use_idx == NULL_IDX) {
05409 cmd_line_flags.implicit_use_idx = start_idx;
05410 }
05411 else {
05412 fp_idx = cmd_line_flags.implicit_use_idx;
05413
05414
05415
05416 while (FP_NEXT_FILE_IDX(fp_idx) != NULL_IDX) {
05417 fp_idx = FP_NEXT_FILE_IDX(fp_idx);
05418 }
05419 FP_NEXT_FILE_IDX(fp_idx) = start_idx;
05420 }
05421 }
05422
05423 TRACE (Func_Exit, "process_A_option", NULL);
05424
05425 return;
05426
05427 }
05428
05429
05430
05431
05432
05433
05434
05435
05436
05437
05438
05439
05440
05441
05442
05443
05444
05445 static void process_b_option(char *optargs)
05446
05447 {
05448
05449 TRACE (Func_Entry, "process_b_option", NULL);
05450
05451
05452
05453 if (cmd_line_flags.assembly_output) {
05454 ntr_msg_queue(0, 715, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
05455 cmd_line_flags.assembly_output = FALSE;
05456 }
05457
05458 cmd_line_flags.binary_output = TRUE;
05459 strncpy (bin_file, optargs, MAX_FILE_NAME_SIZE);
05460 bin_file[MAX_FILE_NAME_SIZE-1] = EOS;
05461
05462 TRACE (Func_Exit, "process_b_option", NULL);
05463
05464 return;
05465
05466 }
05467
05468
05469
05470
05471
05472
05473
05474
05475
05476
05477
05478
05479
05480
05481
05482
05483
05484 static void process_f_option(char *optargs)
05485
05486 {
05487
05488 TRACE (Func_Entry, "process_f_option", NULL);
05489
05490 if (EQUAL_STRS(optargs, "fixed")) {
05491 cmd_line_flags.src_form = Fixed_Form;
05492 source_form = Fixed_Form;
05493 set_source_form_option = TRUE;
05494 }
05495 else if (EQUAL_STRS(optargs, "free")) {
05496 cmd_line_flags.src_form = Free_Form;
05497 source_form = Free_Form;
05498 set_source_form_option = TRUE;
05499 }
05500 else {
05501 ntr_msg_queue(0, 78, Log_Error, 0, optargs, 'f', ARG_STR_ARG);
05502 }
05503
05504 TRACE (Func_Exit, "process_f_option", NULL);
05505
05506 return;
05507
05508 }
05509
05510
05511
05512
05513
05514
05515
05516
05517
05518
05519
05520
05521
05522
05523
05524
05525
05526 static void process_i_option(char *optargs)
05527 {
05528
05529 TRACE (Func_Entry, "process_i_option", NULL);
05530
05531
05532
05533 set_i_option = TRUE;
05534
05535 if (!EQUAL_STRS(optargs, "32"))
05536 printf("HERERERERE\n");
05537
05538
05539 if (!EQUAL_STRS(optargs, "32")) {
05540 ntr_msg_queue(0, 78, Log_Error, 0, optargs, 'i', ARG_STR_ARG);
05541 }
05542 else if (opt_flags.set_fastint_option) {
05543 ntr_msg_queue(0, 1192, Log_Warning, 0,
05544 "-i\n-O fastint\n-O fastint",
05545 0, MULT_STR_ARG);
05546 }
05547 else if (opt_flags.set_allfastint_option) {
05548 ntr_msg_queue(0, 1192, Log_Warning, 0,
05549 "-i\n-O allfastint\n-O allfastint",
05550 0, MULT_STR_ARG);
05551 }
05552 else if (opt_flags.set_nofastint_option) {
05553 ntr_msg_queue(0, 1192, Log_Warning, 0,
05554 "-i\n-O nofastint\n-O nofastint",
05555 0, MULT_STR_ARG);
05556 }
05557
05558 cmd_line_flags.integer_32 = TRUE;
05559
05560 TRACE (Func_Exit, "process_i_option", NULL);
05561
05562 return;
05563
05564 }
05565
05566
05567
05568
05569
05570
05571
05572
05573
05574
05575
05576
05577
05578
05579
05580
05581
05582
05583 static void process_k_option(char *optargs)
05584
05585 {
05586
05587 TRACE (Func_Entry, "process_k_option", NULL);
05588
05589 # if defined(_ACCEPT_CMD_k)
05590
05591 if (EQUAL_STRS(optargs, "g") || EQUAL_STRS(optargs, "s")) {
05592 cmd_line_flags.solaris_profile = TRUE;
05593 }
05594 else {
05595 ntr_msg_queue(0, 78, Log_Error, 0, optargs, 'k', ARG_STR_ARG);
05596 }
05597 # else
05598 ntr_msg_queue(0, 797, Log_Warning, 0, (char *) NULL, 'k' ,ARG_ARG);
05599 # endif
05600
05601 TRACE (Func_Exit, "process_k_option", NULL);
05602
05603 return;
05604
05605 }
05606
05607
05608
05609
05610
05611
05612
05613
05614
05615
05616
05617
05618
05619
05620
05621
05622
05623 static void process_m_option(char *optargs)
05624
05625 {
05626
05627 TRACE (Func_Entry, "process_m_option", NULL);
05628
05629 if (EQUAL_STRS(optargs, "0")) {
05630 cmd_line_flags.msg_lvl_suppressed = Comment_Lvl;
05631 }
05632 else if (EQUAL_STRS(optargs, "1")) {
05633 cmd_line_flags.msg_lvl_suppressed = Note_Lvl;
05634 }
05635 else if (EQUAL_STRS(optargs, "2")) {
05636 cmd_line_flags.msg_lvl_suppressed = Caution_Lvl;
05637 }
05638 else if (EQUAL_STRS(optargs, "3")) {
05639 cmd_line_flags.msg_lvl_suppressed = Warning_Lvl;
05640 }
05641 else if (EQUAL_STRS(optargs, "4")) {
05642 cmd_line_flags.msg_lvl_suppressed = Error_Lvl;
05643 }
05644 else {
05645 ntr_msg_queue(0, 78, Log_Error, 0, optargs, 'm', ARG_STR_ARG);
05646 }
05647
05648 TRACE (Func_Exit, "process_m_option", NULL);
05649
05650 return;
05651
05652 }
05653
05654
05655
05656
05657
05658
05659
05660
05661
05662
05663
05664
05665
05666
05667
05668
05669
05670 static void process_S_option(char *optargs)
05671 {
05672 TRACE (Func_Entry, "process_S_option", NULL);
05673
05674
05675
05676 if (cmd_line_flags.binary_output) {
05677 cmd_line_flags.binary_output = FALSE;
05678 }
05679
05680
05681
05682 if (on_off_flags.assembly_listing_file) {
05683 ntr_msg_queue(0, 911, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
05684 on_off_flags.assembly_listing_file = FALSE;
05685 }
05686
05687 cmd_line_flags.assembly_output = TRUE;
05688 strncpy (assembly_file, optargs, MAX_FILE_NAME_SIZE);
05689 assembly_file[MAX_FILE_NAME_SIZE-1] = EOS;
05690
05691 TRACE (Func_Exit, "process_S_option", NULL);
05692
05693 return;
05694
05695 }
05696
05697
05698
05699
05700
05701
05702
05703
05704
05705
05706
05707
05708
05709
05710
05711
05712
05713 static void process_G_option(char *optargs)
05714
05715 {
05716
05717 TRACE (Func_Entry, "process_G_option", NULL);
05718
05719 if (EQUAL_STRS(optargs, "0")) {
05720 cmd_line_flags.debug_lvl = Debug_Lvl_0;
05721 }
05722 else if (EQUAL_STRS(optargs, "1")) {
05723 cmd_line_flags.debug_lvl = Debug_Lvl_1;
05724 }
05725 else if (EQUAL_STRS(optargs, "2")) {
05726 cmd_line_flags.debug_lvl = Debug_Lvl_2;
05727 }
05728 else if (EQUAL_STRS(optargs, "3")) {
05729 ntr_msg_queue(0, 886, Log_Warning, 0, (char *) NULL, 3 ,ARG_ARG);
05730 cmd_line_flags.debug_lvl = Debug_Lvl_3;
05731 }
05732
05733 # if defined(_ACCEPT_CMD_Gd)
05734
05735
05736
05737
05738
05739 else if (EQUAL_STRS(optargs, "d")) {
05740 cmd_line_flags.dwarf_debug = TRUE;
05741 }
05742 # endif
05743
05744 else {
05745 ntr_msg_queue(0, 78, Log_Error, 0, optargs, 'G', ARG_STR_ARG);
05746 }
05747
05748 TRACE (Func_Exit, "process_G_option", NULL);
05749
05750 return;
05751
05752 }
05753
05754
05755
05756
05757
05758
05759
05760
05761
05762
05763
05764
05765
05766
05767
05768
05769
05770 static void process_v_option(char *optargs)
05771
05772 {
05773
05774 TRACE (Func_Entry, "process_v_option", NULL);
05775
05776 #if defined(_DEBUG) && defined(_ENABLE_FEI)
05777 process_v_dbg_flags (optargs);
05778 #else
05779
05780 ntr_msg_queue(0, 77, Log_Error, 0, (char *) NULL, 'v' ,ARG_ARG);
05781 #endif
05782
05783 TRACE (Func_Exit, "process_v_option", NULL);
05784
05785 return;
05786
05787 }
05788
05789
05790
05791
05792
05793
05794
05795
05796
05797
05798
05799
05800
05801
05802
05803
05804
05805
05806 static void process_N_option(char *optargs)
05807
05808 {
05809
05810 TRACE (Func_Entry, "process_N_option", NULL);
05811
05812 if (cmd_line_flags.src_form != Fixed_Form) {
05813
05814
05815
05816 ntr_msg_queue(0, 11, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
05817 }
05818 else if (EQUAL_STRS(optargs, "72")) {
05819 cmd_line_flags.line_size_80 = FALSE;
05820 cmd_line_flags.line_size_132 = FALSE;
05821 }
05822 else if (EQUAL_STRS(optargs, "80")) {
05823 cmd_line_flags.line_size_80 = TRUE;
05824 cmd_line_flags.line_size_132 = FALSE;
05825 }
05826 else if (EQUAL_STRS(optargs, "120")) {
05827 ntr_msg_queue(0, 1659, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
05828 cmd_line_flags.line_size_132 = TRUE;
05829 cmd_line_flags.line_size_80 = FALSE;
05830 }
05831 else if (EQUAL_STRS(optargs, "132")) {
05832 cmd_line_flags.line_size_132 = TRUE;
05833 cmd_line_flags.line_size_80 = FALSE;
05834 }
05835 else {
05836 ntr_msg_queue(0, 78, Log_Error, 0, optargs, 'N', ARG_STR_ARG);
05837 }
05838
05839 TRACE (Func_Exit, "process_N_option", NULL);
05840
05841 return;
05842
05843 }
05844
05845
05846
05847
05848
05849
05850
05851
05852
05853
05854
05855
05856
05857
05858
05859
05860
05861 static void process_X_option(char *optargs)
05862
05863 {
05864 # if defined(_ACCEPT_CMD_X)
05865 char *opt_chk;
05866 int n_pes;
05867 # endif
05868
05869
05870 TRACE (Func_Entry, "process_X_option", NULL);
05871
05872 # if defined(_ACCEPT_CMD_X)
05873
05874
05875
05876 if (*optargs == 'm') {
05877 cmd_line_flags.malleable = TRUE;
05878
05879 if (set_MPP_num_pes) {
05880 set_MPP_num_pes = FALSE;
05881
05882
05883
05884 ntr_msg_queue(0, 1231, Log_Warning, 0, "m", 0, STR_ARG);
05885
05886 # if defined(_TARGET_OS_MAX)
05887 cmd_line_flags.MPP_num_pes = 0;
05888 # else
05889 cmd_line_flags.MPP_num_pes = 1;
05890 # endif
05891 }
05892 }
05893 else {
05894
05895 opt_chk = optargs;
05896
05897 while (isdigit(*opt_chk)) {
05898 opt_chk++;
05899 }
05900
05901 n_pes = atoi (optargs);
05902
05903 if (*opt_chk != EOS) {
05904 ntr_msg_queue(0, 78, Log_Error, 0, optargs, 'X', ARG_STR_ARG);
05905 }
05906 else if (cmd_line_flags.malleable) {
05907 ntr_msg_queue(0, 1231, Log_Warning, 0, optargs, 0, STR_ARG);
05908 cmd_line_flags.malleable = FALSE;
05909 }
05910 else if (n_pes < 1 || n_pes > 2048) {
05911 ntr_msg_queue(0, 1238, Log_Error, 0, optargs, 0, STR_ARG);
05912 }
05913
05914 set_MPP_num_pes = TRUE;
05915 cmd_line_flags.MPP_num_pes = n_pes;
05916 }
05917
05918 # else
05919 ntr_msg_queue(0, 797, Log_Warning, 0, (char *) NULL, 'X' ,ARG_ARG);
05920 # endif
05921
05922 TRACE (Func_Exit, "process_X_option", NULL);
05923
05924 return;
05925
05926 }
05927
05928
05929
05930
05931
05932
05933
05934
05935
05936
05937
05938
05939
05940
05941
05942
05943
05944 static void process_q_option (char *optargs)
05945
05946 {
05947 int ch;
05948 char err_str[2];
05949
05950
05951 TRACE (Func_Entry, "process_q_option", NULL);
05952
05953 while (ch = *optargs++) {
05954
05955 switch (ch) {
05956 case 'e':
05957 cmd_line_flags.expression_eval_expr = TRUE;
05958 break;
05959
05960 case 's':
05961 cmd_line_flags.expression_eval_stmt = TRUE;
05962 break;
05963
05964 default:
05965 err_str[0] = ch;
05966 err_str[1] = EOS;
05967
05968
05969
05970 ntr_msg_queue(0, 78, Log_Error, 0, err_str, 'q', ARG_STR_ARG);
05971 break;
05972 }
05973
05974 }
05975
05976 TRACE (Func_Exit, "process_q_option", NULL);
05977
05978 return;
05979
05980 }
05981
05982
05983
05984
05985
05986
05987
05988
05989
05990
05991
05992
05993
05994
05995
05996
05997
05998 static void process_r_option (char *optargs)
05999
06000 {
06001 int ch;
06002 char err_str[2];
06003
06004
06005 TRACE (Func_Entry, "process_r_option", NULL);
06006
06007 while (ch = *optargs++) {
06008
06009 switch (ch) {
06010 case 'g':
06011
06012 # if defined(_ACCEPT_CMD_ed_g)
06013 on_off_flags.assembly_listing_file = TRUE;
06014
06015
06016
06017 if (cmd_line_flags.assembly_output) {
06018 ntr_msg_queue(0, 388, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
06019 cmd_line_flags.assembly_output = FALSE;
06020 cmd_line_flags.binary_output = TRUE;
06021 }
06022 # else
06023 ntr_msg_queue(0, 744, Log_Warning, 0, "g", 'r', ARG_STR_ARG);
06024 # endif
06025 break;
06026
06027 default:
06028 err_str[0] = ch;
06029 err_str[1] = EOS;
06030
06031
06032
06033 ntr_msg_queue(0, 78, Log_Error, 0, err_str, 'r', ARG_STR_ARG);
06034 break;
06035 }
06036 }
06037
06038 TRACE (Func_Exit, "process_r_option", NULL);
06039
06040 return;
06041
06042 }
06043
06044
06045
06046
06047
06048
06049
06050
06051
06052
06053
06054
06055
06056
06057
06058
06059
06060 static void process_R_option (char *optargs)
06061
06062 {
06063 int ch;
06064 char err_str[2];
06065 char *cp;
06066
06067
06068 TRACE (Func_Entry, "process_R_option", NULL);
06069
06070 while (ch = *optargs++) {
06071
06072 switch (ch) {
06073 case 'a':
06074 cmd_line_flags.runtime_argument = TRUE;
06075 break;
06076
06077 case 'b':
06078 cmd_line_flags.runtime_bounds = TRUE;
06079 break;
06080
06081 case 'c':
06082 cmd_line_flags.runtime_conformance = TRUE;
06083 break;
06084
06085 case 'C':
06086 cmd_line_flags.runtime_arg_call = TRUE;
06087 break;
06088
06089 case 'E':
06090 cmd_line_flags.runtime_arg_entry = TRUE;
06091 break;
06092
06093 case 'M':
06094
06095 while (*optargs != EOS && isdigit(*optargs)) {
06096
06097 for (cp = optargs;
06098 *optargs != BLANK && *optargs != COMMA && *optargs != EOS;
06099 ++optargs);
06100
06101 if (*optargs != EOS) {
06102 *optargs = EOS;
06103 *optargs++;
06104 }
06105
06106 num_argchck_suppress_msg++;
06107 argchck_suppress_msg[num_argchck_suppress_msg] = atoi(cp);
06108 }
06109
06110 argchck_suppress_msg[num_argchck_suppress_msg+1] = 0;
06111 break;
06112
06113 case 'n':
06114 cmd_line_flags.runtime_arg_count_only = TRUE;
06115 break;
06116
06117 case 'p':
06118 cmd_line_flags.runtime_ptr_chk = TRUE;
06119 break;
06120
06121 case 's':
06122 cmd_line_flags.runtime_substring = TRUE;
06123 break;
06124
06125 default:
06126 err_str[0] = ch;
06127 err_str[1] = EOS;
06128
06129
06130
06131 ntr_msg_queue(0, 78, Log_Error, 0, err_str, 'R', ARG_STR_ARG);
06132 break;
06133 }
06134 }
06135
06136 TRACE (Func_Exit, "process_R_option", NULL);
06137
06138 return;
06139
06140 }
06141
06142
06143
06144
06145
06146
06147
06148
06149
06150
06151
06152
06153
06154
06155
06156
06157
06158 static void process_s_option (char *optargs)
06159 {
06160 TRACE (Func_Entry, "process_s_option", NULL);
06161
06162 if (EQUAL_STRS(optargs, "integer8")) {
06163 cmd_line_flags.s_integer8 = TRUE;
06164 }
06165 else if (EQUAL_STRS(optargs, "logical8")) {
06166 cmd_line_flags.s_logical8 = TRUE;
06167 }
06168 else if (EQUAL_STRS(optargs, "real8")) {
06169 cmd_line_flags.s_real8 = TRUE;
06170 }
06171 else if (EQUAL_STRS(optargs, "complex8")) {
06172 cmd_line_flags.s_complex8 = TRUE;
06173 }
06174 else if (EQUAL_STRS(optargs, "doubleprecision16")) {
06175 cmd_line_flags.s_doubleprecision16 = TRUE;
06176 }
06177 else if (EQUAL_STRS(optargs, "doublecomplex16")) {
06178 cmd_line_flags.s_doublecomplex16 = TRUE;
06179 }
06180 else if (EQUAL_STRS(optargs, "pointer8")) {
06181 cmd_line_flags.s_pointer8 = TRUE;
06182 }
06183 else if (EQUAL_STRS(optargs, "cf77types")) {
06184
06185 # if defined(_ACCEPT_CMD_s_cf77types)
06186 cmd_line_flags.s_cf77types = TRUE;
06187 ntr_msg_queue(0, 1172, Log_Warning, 0, (char *) NULL, 0, NO_ARG);
06188 # else
06189 ntr_msg_queue(0, 744, Log_Warning, 0, "cf77types", 's', ARG_STR_ARG);
06190 # endif
06191 }
06192 else if (EQUAL_STRS(optargs, "float64")) {
06193
06194 # if defined(_ACCEPT_CMD_s_64)
06195 cmd_line_flags.s_float64 = TRUE;
06196 # else
06197 ntr_msg_queue(0, 744, Log_Warning, 0, "float64", 's', ARG_STR_ARG);
06198 # endif
06199 }
06200 else if (EQUAL_STRS(optargs, "default64")) {
06201
06202 # if defined(_ACCEPT_CMD_s_64)
06203 cmd_line_flags.s_float64 = TRUE;
06204 cmd_line_flags.s_default64 = TRUE;
06205 # else
06206 ntr_msg_queue(0, 744, Log_Warning, 0, "default64", 's', ARG_STR_ARG);
06207 # endif
06208 }
06209 else if (EQUAL_STRS(optargs, "default32")) {
06210
06211 # if defined(_ACCEPT_CMD_s_32)
06212 cmd_line_flags.s_default32 = TRUE;
06213 # else
06214 ntr_msg_queue(0, 744, Log_Warning, 0, "default32", 's', ARG_STR_ARG);
06215 # endif
06216 }
06217 else {
06218 ntr_msg_queue(0, 78, Log_Error, 0, optargs, 's', ARG_STR_ARG);
06219 }
06220
06221 TRACE (Func_Exit, "process_s_option", NULL);
06222
06223 return;
06224
06225 }
06226
06227
06228
06229
06230
06231
06232
06233
06234
06235
06236
06237
06238
06239
06240
06241
06242
06243 static void process_D_option(char *optargs)
06244
06245 {
06246 int idx;
06247 char str[MAX_ID_LEN+1];
06248 char *value;
06249
06250
06251 TRACE (Func_Entry, "process_D_option", NULL);
06252
06253 idx = 0;
06254
06255 while (optargs[idx] != EQUAL && optargs[idx] != EOS && idx < MAX_ID_LEN) {
06256 str[idx] = optargs[idx];
06257 idx++;
06258 }
06259
06260 str[idx] = '\0';
06261
06262 if (optargs[idx] != EQUAL && optargs[idx] != EOS) {
06263
06264 ntr_msg_queue(0, 78, Log_Error, 0, optargs, 'D', ARG_STR_ARG);
06265 }
06266
06267 if (optargs[idx] == EQUAL) {
06268 idx++;
06269 value = &(optargs[idx]);
06270 }
06271 else {
06272 value = NULL;
06273 }
06274
06275 if (! enter_cmd_line_cc_define(str, value, TRUE)) {
06276
06277 ntr_msg_queue(0, 78, Log_Error, 0, optargs, 'D', ARG_STR_ARG);
06278 }
06279
06280 TRACE (Func_Exit, "process_D_option", NULL);
06281
06282 return;
06283
06284 }
06285
06286
06287
06288
06289
06290
06291
06292
06293
06294
06295
06296
06297
06298
06299
06300
06301
06302 static void process_U_option(char *optargs)
06303
06304 {
06305 int idx;
06306 char str[MAX_ID_LEN+1];
06307
06308
06309 TRACE (Func_Entry, "process_U_option", NULL);
06310
06311 idx = 0;
06312
06313 while (optargs[idx] != EOS && idx < MAX_ID_LEN) {
06314 str[idx] = optargs[idx];
06315 idx++;
06316 }
06317
06318 str[idx] = '\0';
06319
06320 if (optargs[idx] != EOS) {
06321 ntr_msg_queue(0, 78, Log_Error, 0, optargs, 'U', ARG_STR_ARG);
06322 }
06323
06324 if (! enter_cmd_line_cc_define(str, NULL, FALSE)) {
06325
06326 ntr_msg_queue(0, 78, Log_Error, 0, optargs, 'U', ARG_STR_ARG);
06327 }
06328
06329 TRACE (Func_Exit, "process_U_option", NULL);
06330
06331 return;
06332
06333 }
06334
06335
06336
06337
06338
06339
06340
06341
06342
06343
06344
06345
06346
06347
06348
06349
06350 static void validate_s_option( void )
06351
06352 {
06353 TRACE (Func_Entry, "validate_s_option", NULL);
06354
06355 if (cmd_line_flags.s_float64) {
06356
06357 if (cmd_line_flags.s_real8) {
06358 cmd_line_flags.s_real8 = FALSE;
06359 ntr_msg_queue(0, 1353, Log_Warning, 0,
06360 "-s float64\n-s real8\n-s float64",
06361 0, MULT_STR_ARG);
06362 }
06363
06364 if (cmd_line_flags.s_complex8) {
06365 cmd_line_flags.s_complex8 = FALSE;
06366 ntr_msg_queue(0, 1353, Log_Warning, 0,
06367 "-s float64\n-s complex8\n-s float64",
06368 0, MULT_STR_ARG);
06369 }
06370
06371 if (cmd_line_flags.s_doubleprecision16) {
06372 cmd_line_flags.s_doubleprecision16 = FALSE;
06373 ntr_msg_queue(0, 1353, Log_Warning, 0,
06374 "-s float64\n-s doubleprecision16\n-s float64",
06375 0, MULT_STR_ARG);
06376 }
06377
06378 if (cmd_line_flags.s_doublecomplex16) {
06379 cmd_line_flags.s_doublecomplex16 = FALSE;
06380 ntr_msg_queue(0, 1353, Log_Warning, 0,
06381 "-s float64\n-s doublecomplex16\n-s float64",
06382 0, MULT_STR_ARG);
06383 }
06384 }
06385
06386 if (cmd_line_flags.s_default64) {
06387
06388 if (cmd_line_flags.s_integer8) {
06389 cmd_line_flags.s_integer8 = FALSE;
06390 ntr_msg_queue(0, 1353, Log_Warning, 0,
06391 "-s default64\n-s integer8\n-s default64",
06392 0, MULT_STR_ARG);
06393 }
06394
06395 if (cmd_line_flags.s_logical8) {
06396 cmd_line_flags.s_logical8 = FALSE;
06397 ntr_msg_queue(0, 1353, Log_Warning, 0,
06398 "-s default64\n-s logical8\n-s default64",
06399 0, MULT_STR_ARG);
06400 }
06401
06402 if (cmd_line_flags.s_real8) {
06403 cmd_line_flags.s_real8 = FALSE;
06404 ntr_msg_queue(0, 1353, Log_Warning, 0,
06405 "-s default64\n-s real8\n-s default64",
06406 0, MULT_STR_ARG);
06407 }
06408
06409 if (cmd_line_flags.s_complex8) {
06410 cmd_line_flags.s_complex8 = FALSE;
06411 ntr_msg_queue(0, 1353, Log_Warning, 0,
06412 "-s default64\n-s complex8\n-s default64",
06413 0, MULT_STR_ARG);
06414 }
06415
06416 if (cmd_line_flags.s_doubleprecision16) {
06417 cmd_line_flags.s_doubleprecision16 = FALSE;
06418 ntr_msg_queue(0, 1353, Log_Warning, 0,
06419 "-s default64\n-s doubleprecision16\n-s default64",
06420 0, MULT_STR_ARG);
06421 }
06422
06423 if (cmd_line_flags.s_doublecomplex16) {
06424 cmd_line_flags.s_doublecomplex16 = FALSE;
06425 ntr_msg_queue(0, 1353, Log_Warning, 0,
06426 "-s default64\n-s doublecomplex16\n-s default64",
06427 0, MULT_STR_ARG);
06428 }
06429 }
06430
06431 if (cmd_line_flags.s_default32) {
06432
06433 if (cmd_line_flags.s_integer8) {
06434 cmd_line_flags.s_integer8 = FALSE;
06435 ntr_msg_queue(0, 1353, Log_Warning, 0,
06436 "-s default32\n-s integer8\n-s default32",
06437 0, MULT_STR_ARG);
06438 }
06439
06440 if (cmd_line_flags.s_logical8) {
06441 cmd_line_flags.s_logical8 = FALSE;
06442 ntr_msg_queue(0, 1353, Log_Warning, 0,
06443 "-s default3\n-s logical8\n-s default32",
06444 0, MULT_STR_ARG);
06445 }
06446
06447 if (cmd_line_flags.s_real8) {
06448 cmd_line_flags.s_real8 = FALSE;
06449 ntr_msg_queue(0, 1353, Log_Warning, 0,
06450 "-s default32\n-s real8\n-s default32",
06451 0, MULT_STR_ARG);
06452 }
06453
06454 if (cmd_line_flags.s_complex8) {
06455 cmd_line_flags.s_complex8 = FALSE;
06456 ntr_msg_queue(0, 1353, Log_Warning, 0,
06457 "-s default32\n-s complex8\n-s default32",
06458 0, MULT_STR_ARG);
06459 }
06460
06461 if (cmd_line_flags.s_doubleprecision16) {
06462 cmd_line_flags.s_doubleprecision16 = FALSE;
06463 ntr_msg_queue(0, 1353, Log_Warning, 0,
06464 "-s default32\n-s doubleprecision16\n-s default32",
06465 0, MULT_STR_ARG);
06466 }
06467
06468 if (cmd_line_flags.s_doublecomplex16) {
06469 cmd_line_flags.s_doublecomplex16 = FALSE;
06470 ntr_msg_queue(0, 1353, Log_Warning, 0,
06471 "-s default32\n-s doublecomplex16\n-s default32",
06472 0, MULT_STR_ARG);
06473 }
06474 }
06475
06476 if (cmd_line_flags.s_cf77types) {
06477
06478 if (cmd_line_flags.s_integer8) {
06479 cmd_line_flags.s_integer8 = FALSE;
06480 ntr_msg_queue(0, 1353, Log_Warning, 0,
06481 "-s cf77types\n-s integer8\n-s cf77types",
06482 0, MULT_STR_ARG);
06483 }
06484
06485 if (cmd_line_flags.s_logical8) {
06486 cmd_line_flags.s_logical8 = FALSE;
06487 ntr_msg_queue(0, 1353, Log_Warning, 0,
06488 "-s cf77types\n-s logical8\n-s cf77types",
06489 0, MULT_STR_ARG);
06490 }
06491
06492 if (cmd_line_flags.s_real8) {
06493 cmd_line_flags.s_real8 = FALSE;
06494 ntr_msg_queue(0, 1353, Log_Warning, 0,
06495 "-s cf77types\n-s real8\n-s cf77types",
06496 0, MULT_STR_ARG);
06497 }
06498
06499 if (cmd_line_flags.s_complex8) {
06500 cmd_line_flags.s_complex8 = FALSE;
06501 ntr_msg_queue(0, 1353, Log_Warning, 0,
06502 "-s cf77types\n-s complex8\n-s cf77types",
06503 0, MULT_STR_ARG);
06504 }
06505
06506 if (cmd_line_flags.s_doubleprecision16) {
06507 cmd_line_flags.s_doubleprecision16 = FALSE;
06508 ntr_msg_queue(0, 1353, Log_Warning, 0,
06509 "-s cf77types\n-s doubleprecision16\n-s cf77types",
06510 0, MULT_STR_ARG);
06511 }
06512
06513 if (cmd_line_flags.s_doublecomplex16) {
06514 cmd_line_flags.s_doublecomplex16 = FALSE;
06515 ntr_msg_queue(0, 1353, Log_Warning, 0,
06516 "-s cf77types\n-s doublecomplex16\n-s cf77types",
06517 0, MULT_STR_ARG);
06518 }
06519 }
06520
06521 if (!on_off_flags.enable_double_precision) {
06522
06523 if (cmd_line_flags.s_doubleprecision16) {
06524 cmd_line_flags.s_doubleprecision16 = FALSE;
06525 ntr_msg_queue(0, 1353, Log_Warning, 0,
06526 "-dp\n-s doubleprecision16\n-dp",
06527 0, MULT_STR_ARG);
06528 }
06529
06530 if (cmd_line_flags.s_doublecomplex16) {
06531 cmd_line_flags.s_doublecomplex16 = FALSE;
06532 ntr_msg_queue(0, 1353, Log_Warning, 0,
06533 "-dp\n-s doublecomplex16\n-dp",
06534 0, MULT_STR_ARG);
06535 }
06536 }
06537
06538 if (set_i_option) {
06539
06540 if (cmd_line_flags.s_integer8) {
06541 cmd_line_flags.s_integer8 = FALSE;
06542 ntr_msg_queue(0, 1353, Log_Warning, 0,
06543 "-i32\n-s integer8\n-i32",
06544 0, MULT_STR_ARG);
06545 }
06546 }
06547
06548
06549 TRACE (Func_Exit, "validate_s_option", NULL);
06550
06551 return;
06552
06553 }
06554
06555
06556
06557
06558
06559
06560
06561
06562
06563
06564
06565
06566
06567
06568
06569
06570
06571 static void set_system_module_path( void )
06572 {
06573
06574 char *directory;
06575 int idx;
06576 int length;
06577 char *next_dir_ptr;
06578 char *path_var;
06579 char *ptr;
06580 int save_file_path_tbl_idx;
06581
06582 extern boolean is_directory(char *);
06583
06584
06585 TRACE (Func_Entry, "set_system_module_path", NULL);
06586
06587
06588
06589
06590
06591
06592 path_var = SYSTEM_MODULE_USE_VAR;
06593 directory = getenv(path_var);
06594
06595 if (directory != NULL) {
06596
06597
06598
06599
06600 do {
06601 next_dir_ptr = strchr(directory, ':');
06602
06603 if (next_dir_ptr != NULL) {
06604 *next_dir_ptr = '\0';
06605
06606 if (++next_dir_ptr == '\0') {
06607 next_dir_ptr = NULL;
06608 }
06609 }
06610
06611 TBL_REALLOC_CK(file_path_tbl, 1);
06612 CLEAR_TBL_NTRY(file_path_tbl, file_path_tbl_idx);
06613 FP_NAME_IDX(file_path_tbl_idx) = str_pool_idx + 1;
06614 FP_SRCH_THE_FILE(file_path_tbl_idx) = TRUE;
06615 FP_CLASS(file_path_tbl_idx) = Unknown_Fp;
06616 FP_SYSTEM_FILE(file_path_tbl_idx) = TRUE;
06617 length = strlen(directory) + 1;
06618 FP_NAME_LEN(file_path_tbl_idx) = length;
06619 length = WORD_LEN(length);
06620
06621 TBL_REALLOC_CK(str_pool, length);
06622
06623 for (idx = FP_NAME_IDX(file_path_tbl_idx); idx <= str_pool_idx; idx++){
06624 str_pool[idx].name_long = 0;
06625 }
06626
06627 strcpy(FP_NAME_PTR(file_path_tbl_idx), directory);
06628 save_file_path_tbl_idx = file_path_tbl_idx;
06629
06630 # if (defined(_HOST_OS_IRIX) || defined(_HOST_OS_LINUX))
06631
06632 if (is_directory(FP_NAME_PTR(file_path_tbl_idx))) {
06633
06634
06635
06636 TBL_REALLOC_CK(file_path_tbl, 1);
06637 CLEAR_TBL_NTRY(file_path_tbl, file_path_tbl_idx);
06638 FP_NAME_IDX(file_path_tbl_idx) = str_pool_idx + 1;
06639 FP_SRCH_THE_FILE(file_path_tbl_idx) = TRUE;
06640 FP_CLASS(file_path_tbl_idx) = Unknown_Fp;
06641 FP_SYSTEM_FILE(file_path_tbl_idx) = TRUE;
06642 length = (cmd_line_flags.s_pointer8) ? 3:4;
06643 length += FP_NAME_LEN(save_file_path_tbl_idx);
06644 FP_NAME_LEN(file_path_tbl_idx) = length;
06645 length = WORD_LEN(length);
06646 TBL_REALLOC_CK(str_pool, length);
06647
06648 for (idx = FP_NAME_IDX(file_path_tbl_idx);
06649 idx <= str_pool_idx; idx++) {
06650 str_pool[idx].name_long = 0;
06651 }
06652 strcpy(FP_NAME_PTR(file_path_tbl_idx), directory);
06653 ptr = FP_NAME_PTR(file_path_tbl_idx) +
06654 FP_NAME_LEN(save_file_path_tbl_idx) - 1;
06655 strcpy(ptr, (cmd_line_flags.s_pointer8) ? "/64" : "/n32");
06656 idx = module_path_idx;
06657
06658 while (FP_NEXT_FILE_IDX(idx) != NULL_IDX) {
06659 idx = FP_NEXT_FILE_IDX(idx);
06660 }
06661 FP_NEXT_FILE_IDX(idx) = file_path_tbl_idx;
06662 }
06663 # endif
06664
06665 idx = module_path_idx;
06666
06667 while (FP_NEXT_FILE_IDX(idx) != NULL_IDX) {
06668 idx = FP_NEXT_FILE_IDX(idx);
06669 }
06670 FP_NEXT_FILE_IDX(idx) = save_file_path_tbl_idx;
06671 directory = next_dir_ptr;
06672 }
06673 while (directory != NULL);
06674 }
06675 else {
06676 path_var = MODULE_USE_SYSTEM_PATH_VAR;
06677 directory = getenv(path_var);
06678
06679 if (directory != NULL) {
06680 TBL_REALLOC_CK(file_path_tbl, 1);
06681 CLEAR_TBL_NTRY(file_path_tbl, file_path_tbl_idx);
06682 FP_NAME_IDX(file_path_tbl_idx) = str_pool_idx + 1;
06683 FP_SRCH_THE_FILE(file_path_tbl_idx) = TRUE;
06684 FP_CLASS(file_path_tbl_idx) = Unknown_Fp;
06685 FP_SYSTEM_FILE(file_path_tbl_idx) = TRUE;
06686
06687 # if (defined(_HOST_OS_IRIX) || defined(_HOST_OS_LINUX))
06688 length = strlen(directory) + 1;
06689 # else
06690 length = strlen(directory) + strlen(MODULE_USE_SYSTEM_FILE) + 1;
06691 # endif
06692
06693 FP_NAME_LEN(file_path_tbl_idx) = length;
06694 length = WORD_LEN(length);
06695
06696 TBL_REALLOC_CK(str_pool, length);
06697
06698 for (idx = FP_NAME_IDX(file_path_tbl_idx); idx <= str_pool_idx; idx++){
06699 str_pool[idx].name_long = 0;
06700 }
06701
06702 strcpy(FP_NAME_PTR(file_path_tbl_idx), directory);
06703
06704 # if ! (defined(_HOST_OS_IRIX) || defined(_HOST_OS_LINUX))
06705 ptr = FP_NAME_PTR(file_path_tbl_idx) + strlen(directory);
06706 strcpy(ptr, "/");
06707 strcpy(++ptr, MODULE_USE_SYSTEM_FILE);
06708 # endif
06709 idx = module_path_idx;
06710
06711 while (FP_NEXT_FILE_IDX(idx) != NULL_IDX) {
06712 idx = FP_NEXT_FILE_IDX(idx);
06713 }
06714 FP_NEXT_FILE_IDX(idx) = file_path_tbl_idx;
06715 }
06716 }
06717
06718 TRACE (Func_Exit, "set_system_module_path", NULL);
06719
06720 return;
06721
06722 }
06723
06724
06725
06726
06727
06728
06729
06730
06731
06732
06733
06734
06735
06736
06737
06738
06739
06740 static void process_reshape_array(char *optargs)
06741
06742 {
06743 boolean found_one;
06744 int fp_idx;
06745 int idx;
06746 int length;
06747 char *array_name;
06748 int start_idx;
06749 char *str_ptr;
06750
06751
06752 TRACE (Func_Entry, "process_reshape_array", NULL);
06753
06754 start_idx = file_path_tbl_idx + 1;
06755 found_one = FALSE;
06756 opt_flags.reshape = TRUE;
06757
06758 while (*optargs != EOS) {
06759
06760 for (array_name = optargs;
06761 *optargs != BLANK && *optargs != COMMA && *optargs != EOS;
06762 ++optargs);
06763
06764 if (*optargs != EOS) {
06765 *optargs = EOS;
06766 *optargs++;
06767 }
06768
06769 if (found_one) {
06770 FP_NEXT_FILE_IDX(file_path_tbl_idx) = file_path_tbl_idx + 1;
06771 }
06772
06773 TBL_REALLOC_CK(file_path_tbl, 1);
06774 CLEAR_TBL_NTRY(file_path_tbl, file_path_tbl_idx);
06775
06776 found_one = TRUE;
06777 FP_NAME_IDX(file_path_tbl_idx) = str_pool_idx + 1;
06778 length = strlen(array_name);
06779 FP_CLASS(file_path_tbl_idx) = Reshape_Array_Fp;
06780 FP_NAME_LEN(file_path_tbl_idx) = length;
06781
06782 TBL_REALLOC_CK(str_pool, WORD_LEN(length));
06783
06784 str_pool[str_pool_idx].name_long = 0;
06785
06786 str_ptr = &str_pool[FP_NAME_IDX(file_path_tbl_idx)].name_char;
06787
06788 for (idx = 0; idx < length; idx++) {
06789 str_ptr[idx] = toupper(array_name[idx]);
06790 }
06791 }
06792
06793 if (found_one) {
06794
06795 if (opt_flags.reshape_idx == NULL_IDX) {
06796 opt_flags.reshape_idx = start_idx;
06797 }
06798 else {
06799 fp_idx = opt_flags.reshape_idx;
06800
06801
06802
06803 while (FP_NEXT_FILE_IDX(fp_idx) != NULL_IDX) {
06804 fp_idx = FP_NEXT_FILE_IDX(fp_idx);
06805 }
06806 FP_NEXT_FILE_IDX(fp_idx) = start_idx;
06807 }
06808 }
06809
06810 # if !defined(_ACCEPT_CMD_O_RESHAPE)
06811 opt_flags.reshape_idx = NULL_IDX;
06812 PRINTMSG (0, 744, Log_Warning, 0, 'O', "reshape");
06813 # endif
06814
06815 TRACE (Func_Exit, "process_reshape_array", NULL);
06816
06817 return;
06818
06819 }
06820
06821
06822
06823
06824
06825
06826
06827
06828
06829
06830
06831
06832
06833
06834
06835
06836
06837 static void process_J_option(char *optargs)
06838
06839 {
06840
06841 TRACE (Func_Entry, "process_J_option", NULL);
06842
06843 # if defined(_ACCEPT_CMD_J)
06844 strncpy (mod_out_path, optargs, MAX_FILE_NAME_SIZE);
06845 mod_out_path[MAX_FILE_NAME_SIZE-1] = EOS;
06846 cmd_line_flags.mod_out_path = TRUE;
06847 # else
06848 ntr_msg_queue(0, 77, Log_Error, 0, (char *) NULL, 'J', ARG_ARG);
06849 # endif
06850
06851 TRACE (Func_Exit, "process_J_option", NULL);
06852
06853 return;
06854
06855 }
06856
06857
06858
06859
06860
06861
06862
06863
06864
06865
06866 static void dump_options(void)
06867 {
06868 int i;
06869 char *all_options[] = {
06870 " ",
06871 "The following options are available in the Open64 frontend:",
06872 "-a: memory options ",
06873 " lign32",
06874 " lign64",
06875 " dalign",
06876 " static_threadprivate",
06877 " taskcommon",
06878 " pad",
06879 "-b: binary file name ",
06880 "-d: off flags",
06881 "-e: on flags",
06882 "-f: souce format (-ffree or -ffixed) ",
06883 "-g: -G O",
06884 "-i: integer size",
06885 "-k: Solaris profiling",
06886 "-m: process message level options",
06887 "-O: optimization options",
06888 "-p: module path name ",
06889 "-q: expression evaluator args passed via argv",
06890 "-r: runtime checking options passed via argv",
06891 "-R: runtime checking options passed via argv",
06892 "-s: size options passed via argv",
06893 " integer8",
06894 " logical8",
06895 " real8",
06896 " complex8",
06897 " doubleprecision16",
06898 " doublecomplex16",
06899 " pointer8",
06900 " cf77types",
06901 " float64",
06902 " default64",
06903 " default32",
06904 "-S: cal file option",
06905 "-t: the command line truncation option passed via argv (t switch)",
06906 "-u: command line dump options passed via argv(u<switch>), note there should be no space after \'u\')",
06907 " The following options are available in a compiler with -u: ",
06908 " ",
06909 " abort_ansi Abort compilation after first ANSI msg.",
06910 " cray_compatible Sgi turns s_default64 on, int1,2 off.",
06911 " f Unimplemented - controls fortran output.",
06912 " dsm Set by mongoose driver - not a user option.",
06913 " fmm Controls f-- prototype.",
06914 " fmm1 Controls f-- prototype.",
06915 " fmm2 Controls f-- prototype.",
06916 " mod_version Prints each module version number being read in",
06917 " mp Allow recognition of the SGI directives.",
06918 " no_dim_pad Do not pad out missing dimensions.",
06919 " no_mod_output Do not do module output.",
06920 " open_mp Allow recognition of the open mp directives.",
06921 " pack_half_word Turn on component packing for sdefault32",
06922 " preinline= Create an inline template for this file.",
06923 " pvp_test Used for meta development.",
06924 " show Show input command line to frontend.",
06925 " ",
06926 " The following options are available in a debug compiler with -u:",
06927 " ",
06928 " all Dump all tables. Do not do any tracing.",
06929 " bd Dump the bounds table.",
06930 " blk Dump the Block Stack.",
06931 " cmd Dump the commandline table.",
06932 " cn Dump the Constant table.",
06933 " defines Dump the build definitions.",
06934 " file= Specify the name of the debug output file.",
06935 " fortran Dump the output IR in a Fortran format.",
06936 " fp Dump the File Path table.",
06937 " ftrace Activate the function trace.",
06938 " gl Dump the Global Line table.",
06939 " intrin Dump the Intrinsic table.",
06940 " ir1 Dump the IR after Pass 1.",
06941 " ir2 Dump the IR after Pass 2.",
06942 " ir3 Dump the IR after inlining.",
06943 " ir4 Dump the IR after swapping dimensions.",
06944 " mem_report Provide a report of front-end memory usage.",
06945 " msg Issue an abort for all zero line numbers.",
06946 " mtrace Trace front-end memory usage.",
06947 " names Dump the local, global and hidden name tables.",
06948 " pdg Dump all calls to the PGDCS interface.",
06949 " pdt Dump PDT info while searching for modules.",
06950 " sb Dump the Storage Block table.",
06951 " scp Dump the scope table.",
06952 " src Dump whole source program.",
06953 " stderr Output msgs to stderr rather than ordering.",
06954 " stmt Dump each statement.",
06955 " sytb Dump the symbol table.",
06956 " typ Dump the Type table.",
06957 " cnout Dump constants as binary to stdout.",
06958 "-v: pdgcs debug option",
06959 "-z: clean up whirl (required for use with OpenAD/OpenAnalysis)",
06960 "-A: add use names to the files path tables for implicit use",
06961 "-C: CIF file output is requested via the -C option",
06962 "-D: define a preprocessing id",
06963 "-x: disregard CDIRs",
06964 "-F: fortran macro expansion",
06965 "-G: debug option",
06966 "-I: include option",
06967 "-J: .mod output locate",
06968 "-M: disable message numbers",
06969 "-N: fixed line size",
06970 "-P: position independent code model",
06971 "-U: undefine a preprocessing id",
06972 "-V: version option",
06973 "-X: MPP num PE's option",
06974 "-Y: ccg debug options",
06975 "-Z: co_array fortran",
06976 " ",
06977 "If you need to know arguments of option WHAT,mostly you can get the information by reading:",
06978 "\"process_WHAT_option\" in the source file cmd_line.c.",
06979 " ",
06980 "DONE"
06981 };
06982
06983 i=0;
06984 while (strcmp(all_options[i],"DONE")) printf("%s\n",all_options[i++]);
06985 return;
06986 }