Commit e9b4fabf by Jeff Law

acconfig.h (HAVE_VOLATILE): Insert stub for autoconf.

        * acconfig.h (HAVE_VOLATILE): Insert stub for autoconf.
        * alocal.m4 (GCC_C_VOLATILE): New autoconf test.
        * configure.in: Use GCC_C_VOLATILE.
        * system.h (volatile): Define as empty if no volatile support is
        available.
        * genemit.c (output_add_clobbers): Removed unused variable 'i' from
        generated fucntion.

From-SVN: r19653
parent 846522cb
Sun May 10 02:27:03 1998 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* acconfig.h (HAVE_VOLATILE): Insert stub for autoconf.
* alocal.m4 (GCC_C_VOLATILE): New autoconf test.
* configure.in: Use GCC_C_VOLATILE.
* system.h (volatile): Define as empty if no volatile support is
available.
Sun May 10 01:21:43 1998 Jeffrey A Law (law@cygnus.com)
* genemit.c (output_add_clobbers): Removed unused variable 'i' from
generated fucntion.
Sat May 9 02:02:15 1998 Richard Henderson <rth@cygnus.com>
* loop.c (get_condition): Don't combine when either compare is MODE_CC.
......
......@@ -4,6 +4,9 @@
/* Define if your cpp understands the stringify operator. */
#undef HAVE_CPP_STRINGIFY
/* Define if your compiler understands volatile. */
#undef HAVE_VOLATILE
/* Define if you have a working <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
......
......@@ -143,6 +143,16 @@ fi
AC_SUBST(LN)dnl
])
dnl See whether the stage1 host compiler accepts the volatile keyword.
AC_DEFUN(GCC_C_VOLATILE,
[AC_CACHE_CHECK([for volatile], gcc_cv_c_volatile,
[AC_TRY_COMPILE(, [volatile int foo;],
gcc_cv_c_volatile=yes, gcc_cv_c_volatile=no)])
if test $gcc_cv_c_volatile = yes ; then
AC_DEFINE(HAVE_VOLATILE)
fi
])
AC_DEFUN(EGCS_PROG_INSTALL,
[AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
# Find a good install program. We prefer a C program (faster),
......
......@@ -5,6 +5,9 @@
/* Define if your cpp understands the stringify operator. */
#undef HAVE_CPP_STRINGIFY
/* Define if your compiler understands volatile. */
#undef HAVE_VOLATILE
/* Define if you have a working <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
......
......@@ -143,6 +143,7 @@ AC_PROG_AWK
AC_PROG_LEX
GCC_PROG_LN
GCC_PROG_LN_S
GCC_C_VOLATILE
AC_PROG_RANLIB
AC_PROG_YACC
EGCS_PROG_INSTALL
......
......@@ -620,7 +620,6 @@ output_add_clobbers ()
printf ("\n\nvoid\nadd_clobbers (pattern, insn_code_number)\n");
printf (" rtx pattern;\n int insn_code_number;\n");
printf ("{\n");
printf (" int i;\n\n");
printf (" switch (insn_code_number)\n");
printf (" {\n");
......
......@@ -210,6 +210,12 @@ extern char *getenv ();
extern char *sbrk ();
#endif
/* HAVE_VOLATILE only refers to the stage1 compiler. We also check
__STDC__ and assume gcc sets it and has volatile in stage >=2. */
#if !defined(HAVE_VOLATILE) && !defined(__STDC__) && !defined(volatile)
#define volatile
#endif
/* Redefine abort to report an internal error w/o coredump, and reporting the
location of the error in the source file. */
#ifndef abort
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment