PR libfortran/32021
authorfxcoudert <fxcoudert@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 4 Oct 2007 15:18:48 +0000 (15:18 +0000)
committerfxcoudert <fxcoudert@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 4 Oct 2007 15:18:48 +0000 (15:18 +0000)
* runtime/environ.c (init_mem, show_mem, init_round, show_round,
init_precision, show_precision, init_signal, show_signal): Remove.
(variable_table): Remove GFORTRAN_MEM_INIT, GFORTRAN_MEM_CHECK,
GFORTRAN_SIGHUP, GFORTRAN_SIGINT, GFORTRAN_FPU_ROUND and
GFORTRAN_FPU_PRECISION.
* libgfortran.h (options_t): Remove mem_check, fpu_round,
fpu_precision, sighup, sigint, allocate_init_flag and
allocate_init_value.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@129014 138bc75d-0d04-0410-961f-82ee72b054a4

libgfortran/ChangeLog
libgfortran/libgfortran.h
libgfortran/runtime/environ.c

index a249ded..a5a6731 100644 (file)
@@ -1,8 +1,20 @@
+2007-10-04  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
+
+       PR libfortran/32021
+       * runtime/environ.c (init_mem, show_mem, init_round, show_round,
+       init_precision, show_precision, init_signal, show_signal): Remove.
+       (variable_table): Remove GFORTRAN_MEM_INIT, GFORTRAN_MEM_CHECK,
+       GFORTRAN_SIGHUP, GFORTRAN_SIGINT, GFORTRAN_FPU_ROUND and
+       GFORTRAN_FPU_PRECISION.
+       * libgfortran.h (options_t): Remove mem_check, fpu_round,
+       fpu_precision, sighup, sigint, allocate_init_flag and
+       allocate_init_value.
+
 2007-10-02  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
 
        PR libfortran/33253
        * io/list_read.c (read_character): Use DELIM_APOSTROPHE and DELIM_QUOTE
-        and quote value in check of first character in string.
+       and quote value in check of first character in string.
 
 2007-10-02  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
 
index 6a702c4..8d80998 100644 (file)
@@ -344,19 +344,13 @@ typedef GFC_ARRAY_DESCRIPTOR (GFC_MAX_DIMENSIONS, GFC_LOGICAL_16) gfc_array_l16;
 typedef struct
 {
   int stdin_unit, stdout_unit, stderr_unit, optional_plus;
-  int allocate_init_flag, allocate_init_value;
   int locus;
 
   int separator_len;
   const char *separator;
 
-  int mem_check;
   int use_stderr, all_unbuffered, default_recl;
-
-  int fpu_round, fpu_precision, fpe;
-
-  int sighup, sigint;
-  int dump_core, backtrace;
+  int fpe, dump_core, backtrace;
 }
 options_t;
 
index 62e4cfa..ae06abe 100644 (file)
@@ -201,78 +201,6 @@ show_boolean (variable * v)
 }
 
 
-/* init_mem()-- Initialize environment variables that have to do with
- * how memory from an ALLOCATE statement is filled.  A single flag
- * enables filling and a second variable gives the value that is used
- * to initialize the memory. */
-
-static void
-init_mem (variable * v)
-{
-  int offset, n;
-  char *p;
-
-  p = getenv (v->name);
-
-  options.allocate_init_flag = 0;      /* The default */
-
-  if (p == NULL)
-    return;
-
-  if (strcasecmp (p, "NONE") == 0)
-    return;
-
-  /* IEEE-754 Quiet Not-a-Number that will work for single and double
-   * precision.  Look for the 'f95' mantissa in debug dumps. */
-
-  if (strcasecmp (p, "NaN") == 0)
-    {
-      options.allocate_init_flag = 1;
-      options.allocate_init_value = 0xfff80f95;
-      return;
-    }
-
-  /* Interpret the string as a hexadecimal constant */
-
-  n = 0;
-  while (*p)
-    {
-      if (!isxdigit (*p))
-       {
-         v->bad = 1;
-         return;
-       }
-
-      offset = '0';
-      if (islower (*p))
-       offset = 'a';
-      if (isupper (*p))
-       offset = 'A';
-
-      n = (n << 4) | (*p++ - offset);
-    }
-
-  options.allocate_init_flag = 1;
-  options.allocate_init_value = n;
-}
-
-
-static void
-show_mem (variable * v)
-{
-  char *p;
-
-  p = getenv (v->name);
-
-  st_printf ("%s  ", var_source (v));
-
-  if (options.allocate_init_flag)
-    st_printf ("0x%x", options.allocate_init_value);
-
-  st_printf ("\n");
-}
-
-
 static void
 init_sep (variable * v)
 {
@@ -422,43 +350,6 @@ show_choice (variable * v, const choice * c)
 }
 
 
-static void
-init_round (variable * v)
-{
-  init_choice (v, rounding);
-}
-
-static void
-show_round (variable * v)
-{
-  show_choice (v, rounding);
-}
-
-static void
-init_precision (variable * v)
-{
-  init_choice (v, precision);
-}
-
-static void
-show_precision (variable * v)
-{
-  show_choice (v, precision);
-}
-
-static void
-init_signal (variable * v)
-{
-  init_choice (v, signal_choices);
-}
-
-static void
-show_signal (variable * v)
-{
-  show_choice (v, signal_choices);
-}
-
-
 static variable variable_table[] = {
   {"GFORTRAN_STDIN_UNIT", GFC_STDIN_UNIT_NUMBER, &options.stdin_unit,
    init_integer, show_integer,
@@ -504,34 +395,6 @@ static variable variable_table[] = {
    "Separator to use when writing list output.  May contain any number of "
    "spaces\nand at most one comma.  Default is a single space.", 0},
 
-  /* Memory related controls */
-
-  {"GFORTRAN_MEM_INIT", 0, NULL, init_mem, show_mem,
-   "How to initialize allocated memory.  Default value is NONE for no "
-   "initialization\n(faster), NAN for a Not-a-Number with the mantissa "
-   "0x40f95 or a custom\nhexadecimal value", 0},
-
-  {"GFORTRAN_MEM_CHECK", 0, &options.mem_check, init_boolean, show_boolean,
-   "Whether memory still allocated will be reported when the program ends.",
-   0},
-
-  /* Signal handling (Unix).  */
-
-  {"GFORTRAN_SIGHUP", 0, &options.sighup, init_signal, show_signal,
-   "Whether the program will IGNORE or ABORT on SIGHUP.", 0},
-
-  {"GFORTRAN_SIGINT", 0, &options.sigint, init_signal, show_signal,
-   "Whether the program will IGNORE or ABORT on SIGINT.", 0},
-
-  /* Floating point control */
-
-  {"GFORTRAN_FPU_ROUND", 0, &options.fpu_round, init_round, show_round,
-   "Set floating point rounding.  Values are NEAREST, UP, DOWN, ZERO.", 0},
-
-  {"GFORTRAN_FPU_PRECISION", 0, &options.fpu_precision, init_precision,
-   show_precision,
-   "Precision of intermediate results.  Values are 24, 53 and 64.", 0},
-
   /* GFORTRAN_CONVERT_UNIT - Set the default data conversion for
    unformatted I/O.  */
   {"GFORTRAN_CONVERT_UNIT", 0, 0, init_unformatted, show_string,