Commit 9d147085 by Richard Henderson Committed by Richard Henderson

configure.in (HAVE_AS_DWARF2_DEBUG_LINE): New.

        * configure.in (HAVE_AS_DWARF2_DEBUG_LINE): New.  Detect
        whether as accepts .file/.loc and produces dwarf2 line info.
        * dwarf2out.c (DWARF2_ASM_LINE_DEBUG_INFO): Default on if
        the assembler supports it.
        * config.in, configure: Regenerate.

From-SVN: r37534
parent 5b87e928
2000-11-17 Richard Henderson <rth@redhat.com> 2000-11-17 Richard Henderson <rth@redhat.com>
* configure.in (HAVE_AS_DWARF2_DEBUG_LINE): New. Detect
whether as accepts .file/.loc and produces dwarf2 line info.
* dwarf2out.c (DWARF2_ASM_LINE_DEBUG_INFO): Default on if
the assembler supports it.
* config.in, configure: Regenerate.
2000-11-17 Richard Henderson <rth@redhat.com>
* fixinc/mkfixinc.sh: Don't disable fixincludes for any linux*. * fixinc/mkfixinc.sh: Don't disable fixincludes for any linux*.
2000-11-17 Jim Wilson <wilson@redhat.com> 2000-11-17 Jim Wilson <wilson@redhat.com>
......
...@@ -443,6 +443,9 @@ ...@@ -443,6 +443,9 @@
/* Define if your assembler supports offsetable %lo(). */ /* Define if your assembler supports offsetable %lo(). */
#undef HAVE_AS_OFFSETABLE_LO10 #undef HAVE_AS_OFFSETABLE_LO10
/* Define if your assembler supports dwarf2 .file/.loc directives. */
#undef HAVE_AS_DWARF2_DEBUG_LINE
/* Define if you want to always select the new-abi for g++. */ /* Define if you want to always select the new-abi for g++. */
#undef ENABLE_NEW_GXX_ABI #undef ENABLE_NEW_GXX_ABI
......
...@@ -5851,7 +5851,7 @@ echo "$ac_t""$gcc_cv_nm" 1>&6 ...@@ -5851,7 +5851,7 @@ echo "$ac_t""$gcc_cv_nm" 1>&6
# Figure out what assembler alignment features are present. # Figure out what assembler alignment features are present.
echo $ac_n "checking assembler alignment features""... $ac_c" 1>&6 echo $ac_n "checking assembler alignment features""... $ac_c" 1>&6
echo "configure:5854: checking assembler alignment features" >&5 echo "configure:5854: checking assembler alignment features" >&5
gcc_cv_as_alignment_features= gcc_cv_as_alignment_features=none
if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then
# Gas version 2.6 and later support for .balign and .p2align. # Gas version 2.6 and later support for .balign and .p2align.
# bytes to skip when using .p2align. # bytes to skip when using .p2align.
...@@ -5899,7 +5899,7 @@ echo "$ac_t""$gcc_cv_as_alignment_features" 1>&6 ...@@ -5899,7 +5899,7 @@ echo "$ac_t""$gcc_cv_as_alignment_features" 1>&6
echo $ac_n "checking assembler subsection support""... $ac_c" 1>&6 echo $ac_n "checking assembler subsection support""... $ac_c" 1>&6
echo "configure:5902: checking assembler subsection support" >&5 echo "configure:5902: checking assembler subsection support" >&5
gcc_cv_as_subsections= gcc_cv_as_subsections=no
if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then
if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 9 -o "$gcc_cv_gas_major_version" -gt 2 && grep 'obj_format = elf' ../gas/Makefile > /dev/null; then if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 9 -o "$gcc_cv_gas_major_version" -gt 2 && grep 'obj_format = elf' ../gas/Makefile > /dev/null; then
gcc_cv_as_subsections="working .subsection -1" gcc_cv_as_subsections="working .subsection -1"
...@@ -5939,7 +5939,7 @@ echo "$ac_t""$gcc_cv_as_subsections" 1>&6 ...@@ -5939,7 +5939,7 @@ echo "$ac_t""$gcc_cv_as_subsections" 1>&6
echo $ac_n "checking assembler weak support""... $ac_c" 1>&6 echo $ac_n "checking assembler weak support""... $ac_c" 1>&6
echo "configure:5942: checking assembler weak support" >&5 echo "configure:5942: checking assembler weak support" >&5
gcc_cv_as_weak= gcc_cv_as_weak=no
if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then
if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 2 -o "$gcc_cv_gas_major_version" -gt 2; then if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 2 -o "$gcc_cv_gas_major_version" -gt 2; then
gcc_cv_as_weak="yes" gcc_cv_as_weak="yes"
...@@ -5962,7 +5962,7 @@ echo "$ac_t""$gcc_cv_as_weak" 1>&6 ...@@ -5962,7 +5962,7 @@ echo "$ac_t""$gcc_cv_as_weak" 1>&6
echo $ac_n "checking assembler hidden support""... $ac_c" 1>&6 echo $ac_n "checking assembler hidden support""... $ac_c" 1>&6
echo "configure:5965: checking assembler hidden support" >&5 echo "configure:5965: checking assembler hidden support" >&5
gcc_cv_as_hidden= gcc_cv_as_hidden=no
if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then
if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 10 -o "$gcc_cv_gas_major_version" -gt 2 && grep 'obj_format = elf' ../gas/Makefile > /dev/null; then if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 10 -o "$gcc_cv_gas_major_version" -gt 2 && grep 'obj_format = elf' ../gas/Makefile > /dev/null; then
gcc_cv_as_hidden="yes" gcc_cv_as_hidden="yes"
...@@ -6157,6 +6157,50 @@ EOF ...@@ -6157,6 +6157,50 @@ EOF
;; ;;
esac esac
echo $ac_n "checking assembler dwarf2 debug_line support""... $ac_c" 1>&6
echo "configure:6162: checking assembler dwarf2 debug_line support" >&5
gcc_cv_as_dwarf2_debug_line=no
# ??? Not all targets support dwarf2 debug_line, even within a version
# of gas. Moreover, we need to emit a valid instruction to trigger any
# info to the output file. So, as supported targets are added to gas 2.11,
# add some instruction here to (also) show we expect this might work.
# ??? Once 2.11 is released, probably need to add first known working
# version to the per-target configury.
case "$target" in
i?86*-*-* | mips*-*-* | alpha*-*-*)
insn="nop"
;;
ia64*-*-*)
insn="nop 0"
;;
esac
if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x;
then
if test "$gcc_cv_gas_major_version" -eq 2 \
-a "$gcc_cv_gas_minor_version" -ge 11 \
-o "$gcc_cv_gas_major_version" -gt 2 \
&& grep 'obj_format = elf' ../gas/Makefile > /dev/null \
&& test x"$insn" != x ; then
gcc_cv_as_dwarf2_debug_line="yes"
fi
elif test x$gcc_cv_as != x -a x"$insn" != x ; then
echo ' .file 0 "conftest.s"' > conftest.s
echo ' .loc 0 3 0' >> conftest.s
echo " $insn" >> conftest.s
if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1 \
&& grep debug_line conftest.o > /dev/null 2>&1 ; then
gcc_cv_as_dwarf2_debug_line="yes"
fi
rm -f conftest.s conftest.o conftest.nm1 conftest.nm2
fi
if test x"$gcc_cv_as_dwarf2_debug_line" = xyes; then
cat >> confdefs.h <<\EOF
#define HAVE_AS_DWARF2_DEBUG_LINE 1
EOF
fi
echo "$ac_t""$gcc_cv_as_dwarf2_debug_line" 1>&6
# Figure out what language subdirectories are present. # Figure out what language subdirectories are present.
# Look if the user specified --enable-languages="..."; if not, use # Look if the user specified --enable-languages="..."; if not, use
# the environment variable $LANGUAGES if defined. $LANGUAGES might # the environment variable $LANGUAGES if defined. $LANGUAGES might
...@@ -6285,7 +6329,7 @@ EOF ...@@ -6285,7 +6329,7 @@ EOF
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
echo "configure:6289: checking whether to enable maintainer-specific portions of Makefiles" >&5 echo "configure:6333: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given. # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode" enableval="$enable_maintainer_mode"
......
...@@ -1210,7 +1210,7 @@ AC_MSG_RESULT($gcc_cv_nm) ...@@ -1210,7 +1210,7 @@ AC_MSG_RESULT($gcc_cv_nm)
# Figure out what assembler alignment features are present. # Figure out what assembler alignment features are present.
AC_MSG_CHECKING(assembler alignment features) AC_MSG_CHECKING(assembler alignment features)
gcc_cv_as_alignment_features= gcc_cv_as_alignment_features=none
if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then
# Gas version 2.6 and later support for .balign and .p2align. # Gas version 2.6 and later support for .balign and .p2align.
# bytes to skip when using .p2align. # bytes to skip when using .p2align.
...@@ -1245,7 +1245,7 @@ fi ...@@ -1245,7 +1245,7 @@ fi
AC_MSG_RESULT($gcc_cv_as_alignment_features) AC_MSG_RESULT($gcc_cv_as_alignment_features)
AC_MSG_CHECKING(assembler subsection support) AC_MSG_CHECKING(assembler subsection support)
gcc_cv_as_subsections= gcc_cv_as_subsections=no
if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then
if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 9 -o "$gcc_cv_gas_major_version" -gt 2 && grep 'obj_format = elf' ../gas/Makefile > /dev/null; then if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 9 -o "$gcc_cv_gas_major_version" -gt 2 && grep 'obj_format = elf' ../gas/Makefile > /dev/null; then
gcc_cv_as_subsections="working .subsection -1" gcc_cv_as_subsections="working .subsection -1"
...@@ -1283,7 +1283,7 @@ fi ...@@ -1283,7 +1283,7 @@ fi
AC_MSG_RESULT($gcc_cv_as_subsections) AC_MSG_RESULT($gcc_cv_as_subsections)
AC_MSG_CHECKING(assembler weak support) AC_MSG_CHECKING(assembler weak support)
gcc_cv_as_weak= gcc_cv_as_weak=no
if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then
if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 2 -o "$gcc_cv_gas_major_version" -gt 2; then if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 2 -o "$gcc_cv_gas_major_version" -gt 2; then
gcc_cv_as_weak="yes" gcc_cv_as_weak="yes"
...@@ -1302,7 +1302,7 @@ fi ...@@ -1302,7 +1302,7 @@ fi
AC_MSG_RESULT($gcc_cv_as_weak) AC_MSG_RESULT($gcc_cv_as_weak)
AC_MSG_CHECKING(assembler hidden support) AC_MSG_CHECKING(assembler hidden support)
gcc_cv_as_hidden= gcc_cv_as_hidden=no
if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then
if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 10 -o "$gcc_cv_gas_major_version" -gt 2 && grep 'obj_format = elf' ../gas/Makefile > /dev/null; then if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 10 -o "$gcc_cv_gas_major_version" -gt 2 && grep 'obj_format = elf' ../gas/Makefile > /dev/null; then
gcc_cv_as_hidden="yes" gcc_cv_as_hidden="yes"
...@@ -1457,6 +1457,47 @@ changequote([,])dnl ...@@ -1457,6 +1457,47 @@ changequote([,])dnl
;; ;;
esac esac
AC_MSG_CHECKING(assembler dwarf2 debug_line support)
gcc_cv_as_dwarf2_debug_line=no
# ??? Not all targets support dwarf2 debug_line, even within a version
# of gas. Moreover, we need to emit a valid instruction to trigger any
# info to the output file. So, as supported targets are added to gas 2.11,
# add some instruction here to (also) show we expect this might work.
# ??? Once 2.11 is released, probably need to add first known working
# version to the per-target configury.
case "$target" in
i?86*-*-* | mips*-*-* | alpha*-*-*)
insn="nop"
;;
ia64*-*-*)
insn="nop 0"
;;
esac
if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x;
then
if test "$gcc_cv_gas_major_version" -eq 2 \
-a "$gcc_cv_gas_minor_version" -ge 11 \
-o "$gcc_cv_gas_major_version" -gt 2 \
&& grep 'obj_format = elf' ../gas/Makefile > /dev/null \
&& test x"$insn" != x ; then
gcc_cv_as_dwarf2_debug_line="yes"
fi
elif test x$gcc_cv_as != x -a x"$insn" != x ; then
echo ' .file 0 "conftest.s"' > conftest.s
echo ' .loc 0 3 0' >> conftest.s
echo " $insn" >> conftest.s
if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1 \
&& grep debug_line conftest.o > /dev/null 2>&1 ; then
gcc_cv_as_dwarf2_debug_line="yes"
fi
rm -f conftest.s conftest.o conftest.nm1 conftest.nm2
fi
if test x"$gcc_cv_as_dwarf2_debug_line" = xyes; then
AC_DEFINE(HAVE_AS_DWARF2_DEBUG_LINE, 1,
[Define if your assembler supports dwarf2 .file/.loc directives.])
fi
AC_MSG_RESULT($gcc_cv_as_dwarf2_debug_line)
# Figure out what language subdirectories are present. # Figure out what language subdirectories are present.
# Look if the user specified --enable-languages="..."; if not, use # Look if the user specified --enable-languages="..."; if not, use
# the environment variable $LANGUAGES if defined. $LANGUAGES might # the environment variable $LANGUAGES if defined. $LANGUAGES might
......
...@@ -3127,10 +3127,14 @@ extern int flag_traditional; ...@@ -3127,10 +3127,14 @@ extern int flag_traditional;
(DWARF_ROUND (2 * DWARF_OFFSET_SIZE + 4, DWARF2_ADDR_SIZE * 2) \ (DWARF_ROUND (2 * DWARF_OFFSET_SIZE + 4, DWARF2_ADDR_SIZE * 2) \
- (2 * DWARF_OFFSET_SIZE + 4)) - (2 * DWARF_OFFSET_SIZE + 4))
/* The default is to have gcc emit the line number tables. */ /* Use assembler line directives if available. */
#ifndef DWARF2_ASM_LINE_DEBUG_INFO #ifndef DWARF2_ASM_LINE_DEBUG_INFO
#ifdef HAVE_AS_DWARF2_DEBUG_LINE
#define DWARF2_ASM_LINE_DEBUG_INFO 1
#else
#define DWARF2_ASM_LINE_DEBUG_INFO 0 #define DWARF2_ASM_LINE_DEBUG_INFO 0
#endif #endif
#endif
/* Define the architecture-dependent minimum instruction length (in bytes). /* Define the architecture-dependent minimum instruction length (in bytes).
In this implementation of DWARF, this field is used for information In this implementation of DWARF, this field is used for information
......
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