From daniel at zuster.org Mon Sep 14 00:22:47 2009
From: daniel at zuster.org (Daniel Dunbar)
Date: Mon, 14 Sep 2009 05:22:47 -0000
Subject: [llvm-commits] [llvm] r81757 - /llvm/trunk/lib/MC/CMakeLists.txt
Message-ID: <200909140522.n8E5MlLt023041@zion.cs.uiuc.edu>
Author: ddunbar
Date: Mon Sep 14 00:22:47 2009
New Revision: 81757
URL: http://llvm.org/viewvc/llvm-project?rev=81757&view=rev
Log:
Update CMake.
Modified:
llvm/trunk/lib/MC/CMakeLists.txt
Modified: llvm/trunk/lib/MC/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/MC/CMakeLists.txt?rev=81757&r1=81756&r2=81757&view=diff
==============================================================================
--- llvm/trunk/lib/MC/CMakeLists.txt (original)
+++ llvm/trunk/lib/MC/CMakeLists.txt Mon Sep 14 00:22:47 2009
@@ -11,6 +11,7 @@
MCDisassembler.cpp
MCExpr.cpp
MCInst.cpp
+ MCInstPrinter.cpp
MCMachOStreamer.cpp
MCNullStreamer.cpp
MCSection.cpp
From daniel at zuster.org Mon Sep 14 00:22:54 2009
From: daniel at zuster.org (Daniel Dunbar)
Date: Mon, 14 Sep 2009 05:22:54 -0000
Subject: [llvm-commits] [llvm] r81758 -
/llvm/trunk/cmake/modules/LLVMLibDeps.cmake
Message-ID: <200909140522.n8E5Ms1T023067@zion.cs.uiuc.edu>
Author: ddunbar
Date: Mon Sep 14 00:22:54 2009
New Revision: 81758
URL: http://llvm.org/viewvc/llvm-project?rev=81758&view=rev
Log:
Update CMake dependencies.
Modified:
llvm/trunk/cmake/modules/LLVMLibDeps.cmake
Modified: llvm/trunk/cmake/modules/LLVMLibDeps.cmake
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/cmake/modules/LLVMLibDeps.cmake?rev=81758&r1=81757&r2=81758&view=diff
==============================================================================
--- llvm/trunk/cmake/modules/LLVMLibDeps.cmake (original)
+++ llvm/trunk/cmake/modules/LLVMLibDeps.cmake Mon Sep 14 00:22:54 2009
@@ -1,7 +1,7 @@
-set(MSVC_LIB_DEPS_LLVMARMAsmPrinter LLVMARMCodeGen LLVMARMInfo LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMSupport LLVMSystem LLVMTarget)
+set(MSVC_LIB_DEPS_LLVMARMAsmPrinter LLVMARMCodeGen LLVMARMInfo LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMARMCodeGen LLVMARMInfo LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMARMInfo LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMAlphaAsmPrinter LLVMAlphaInfo LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMSupport LLVMSystem LLVMTarget)
+set(MSVC_LIB_DEPS_LLVMAlphaAsmPrinter LLVMAlphaInfo LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMAlphaCodeGen LLVMAlphaInfo LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMAlphaInfo LLVMSupport)
set(MSVC_LIB_DEPS_LLVMAnalysis LLVMCore LLVMSupport LLVMSystem LLVMTarget)
@@ -10,12 +10,12 @@
set(MSVC_LIB_DEPS_LLVMAsmPrinter LLVMAnalysis LLVMCodeGen LLVMCore LLVMMC LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMBitReader LLVMCore LLVMSupport LLVMSystem)
set(MSVC_LIB_DEPS_LLVMBitWriter LLVMCore LLVMSupport LLVMSystem)
-set(MSVC_LIB_DEPS_LLVMBlackfinAsmPrinter LLVMAsmPrinter LLVMBlackfinInfo LLVMCodeGen LLVMCore LLVMSupport LLVMSystem LLVMTarget)
+set(MSVC_LIB_DEPS_LLVMBlackfinAsmPrinter LLVMAsmPrinter LLVMBlackfinInfo LLVMCodeGen LLVMCore LLVMMC LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMBlackfinCodeGen LLVMBlackfinInfo LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMTarget)
set(MSVC_LIB_DEPS_LLVMBlackfinInfo LLVMSupport)
set(MSVC_LIB_DEPS_LLVMCBackend LLVMAnalysis LLVMCBackendInfo LLVMCodeGen LLVMCore LLVMScalarOpts LLVMSupport LLVMSystem LLVMTarget LLVMTransformUtils LLVMipa)
set(MSVC_LIB_DEPS_LLVMCBackendInfo LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMCellSPUAsmPrinter LLVMAsmPrinter LLVMCellSPUInfo LLVMCodeGen LLVMCore LLVMSupport LLVMSystem LLVMTarget)
+set(MSVC_LIB_DEPS_LLVMCellSPUAsmPrinter LLVMAsmPrinter LLVMCellSPUInfo LLVMCodeGen LLVMCore LLVMMC LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMCellSPUCodeGen LLVMCellSPUInfo LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMTarget)
set(MSVC_LIB_DEPS_LLVMCellSPUInfo LLVMSupport)
set(MSVC_LIB_DEPS_LLVMCodeGen LLVMAnalysis LLVMCore LLVMMC LLVMScalarOpts LLVMSupport LLVMSystem LLVMTarget LLVMTransformUtils)
@@ -32,26 +32,26 @@
set(MSVC_LIB_DEPS_LLVMMC LLVMSupport LLVMSystem)
set(MSVC_LIB_DEPS_LLVMMSIL LLVMAnalysis LLVMCodeGen LLVMCore LLVMMSILInfo LLVMScalarOpts LLVMSupport LLVMSystem LLVMTarget LLVMTransformUtils LLVMipa)
set(MSVC_LIB_DEPS_LLVMMSILInfo LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMMSP430AsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMSP430Info LLVMSupport LLVMSystem LLVMTarget)
+set(MSVC_LIB_DEPS_LLVMMSP430AsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMMSP430Info LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMMSP430CodeGen LLVMCodeGen LLVMCore LLVMMC LLVMMSP430Info LLVMSelectionDAG LLVMSupport LLVMTarget)
set(MSVC_LIB_DEPS_LLVMMSP430Info LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMMipsAsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMipsCodeGen LLVMMipsInfo LLVMSupport LLVMSystem LLVMTarget)
+set(MSVC_LIB_DEPS_LLVMMipsAsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMMipsCodeGen LLVMMipsInfo LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMMipsCodeGen LLVMCodeGen LLVMCore LLVMMC LLVMMipsInfo LLVMSelectionDAG LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMMipsInfo LLVMSupport)
set(MSVC_LIB_DEPS_LLVMPIC16 LLVMAnalysis LLVMCodeGen LLVMCore LLVMMC LLVMPIC16Info LLVMSelectionDAG LLVMSupport LLVMSystem LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMPIC16AsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMPIC16 LLVMPIC16Info LLVMSupport LLVMSystem LLVMTarget)
+set(MSVC_LIB_DEPS_LLVMPIC16AsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMPIC16 LLVMPIC16Info LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMPIC16Info LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMPowerPCAsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMPowerPCInfo LLVMSupport LLVMSystem LLVMTarget)
+set(MSVC_LIB_DEPS_LLVMPowerPCAsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMPowerPCInfo LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMPowerPCCodeGen LLVMCodeGen LLVMCore LLVMMC LLVMPowerPCInfo LLVMSelectionDAG LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMPowerPCInfo LLVMSupport)
set(MSVC_LIB_DEPS_LLVMScalarOpts LLVMAnalysis LLVMCore LLVMSupport LLVMSystem LLVMTarget LLVMTransformUtils)
set(MSVC_LIB_DEPS_LLVMSelectionDAG LLVMAnalysis LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMSupport LLVMSystem LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMSparcAsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMSparcInfo LLVMSupport LLVMSystem LLVMTarget)
+set(MSVC_LIB_DEPS_LLVMSparcAsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMSparcInfo LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMSparcCodeGen LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSparcInfo LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMSparcInfo LLVMSupport)
set(MSVC_LIB_DEPS_LLVMSupport LLVMSystem)
set(MSVC_LIB_DEPS_LLVMSystem )
-set(MSVC_LIB_DEPS_LLVMSystemZAsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMSupport LLVMSystem LLVMSystemZInfo LLVMTarget)
+set(MSVC_LIB_DEPS_LLVMSystemZAsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMSupport LLVMSystem LLVMSystemZInfo LLVMTarget)
set(MSVC_LIB_DEPS_LLVMSystemZCodeGen LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMSystemZInfo LLVMTarget)
set(MSVC_LIB_DEPS_LLVMSystemZInfo LLVMSupport)
set(MSVC_LIB_DEPS_LLVMTarget LLVMCore LLVMMC LLVMSupport LLVMSystem)
@@ -61,7 +61,7 @@
set(MSVC_LIB_DEPS_LLVMX86CodeGen LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMSystem LLVMTarget LLVMX86Info)
set(MSVC_LIB_DEPS_LLVMX86Info LLVMSupport)
set(MSVC_LIB_DEPS_LLVMXCore LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMSystem LLVMTarget LLVMXCoreInfo)
-set(MSVC_LIB_DEPS_LLVMXCoreAsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMSupport LLVMSystem LLVMTarget LLVMXCoreInfo)
+set(MSVC_LIB_DEPS_LLVMXCoreAsmPrinter LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMSupport LLVMSystem LLVMTarget LLVMXCoreInfo)
set(MSVC_LIB_DEPS_LLVMXCoreInfo LLVMSupport)
set(MSVC_LIB_DEPS_LLVMipa LLVMAnalysis LLVMCore LLVMSupport LLVMSystem)
set(MSVC_LIB_DEPS_LLVMipo LLVMAnalysis LLVMCore LLVMSupport LLVMSystem LLVMTarget LLVMTransformUtils LLVMipa)
From eocallaghan at auroraux.org Mon Sep 14 07:45:07 2009
From: eocallaghan at auroraux.org (Edward O'Callaghan)
Date: Mon, 14 Sep 2009 12:45:07 -0000
Subject: [llvm-commits] [compiler-rt] r81760 - in /compiler-rt/trunk:
CMakeLists.txt lib/CMakeLists.txt lib/arm/CMakeLists.txt
Message-ID: <200909141245.n8ECj8J8029513@zion.cs.uiuc.edu>
Author: evocallaghan
Date: Mon Sep 14 07:45:07 2009
New Revision: 81760
URL: http://llvm.org/viewvc/llvm-project?rev=81760&view=rev
Log:
Update cmake files for arm support hooks.
Added:
compiler-rt/trunk/lib/arm/CMakeLists.txt
Modified:
compiler-rt/trunk/CMakeLists.txt
compiler-rt/trunk/lib/CMakeLists.txt
Modified: compiler-rt/trunk/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/CMakeLists.txt?rev=81760&r1=81759&r2=81760&view=diff
==============================================================================
--- compiler-rt/trunk/CMakeLists.txt (original)
+++ compiler-rt/trunk/CMakeLists.txt Mon Sep 14 07:45:07 2009
@@ -34,7 +34,7 @@
)
SET( Achitectures
- i386 ppc x86_64
+ i386 x86_64 ppc arm
)
SET( Configurations
Modified: compiler-rt/trunk/lib/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/CMakeLists.txt?rev=81760&r1=81759&r2=81760&view=diff
==============================================================================
--- compiler-rt/trunk/lib/CMakeLists.txt (original)
+++ compiler-rt/trunk/lib/CMakeLists.txt Mon Sep 14 07:45:07 2009
@@ -51,6 +51,7 @@
# ADD_SUBDIRECTORY( ppc )
# ADD_SUBDIRECTORY( x86_64 )
# ADD_SUBDIRECTORY( i386 )
+# ADD_SUBDIRECTORY( arm )
#FOREACH( LOOP_VAR ${Achitectures} )
# See ARCHIVE_OUTPUT_DIRECTORY docs.
Added: compiler-rt/trunk/lib/arm/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/arm/CMakeLists.txt?rev=81760&view=auto
==============================================================================
(empty)
From xerxes at zafena.se Mon Sep 14 07:59:02 2009
From: xerxes at zafena.se (=?ISO-8859-1?Q?Xerxes_R=E5nby?=)
Date: Mon, 14 Sep 2009 14:59:02 +0200
Subject: [llvm-commits] ping - [patch] configure.ac ARM TARGET_HAS_JIT
In-Reply-To: <4AA76A91.2030705@zafena.se>
References: <4AA76A91.2030705@zafena.se>
Message-ID: <4AAE3E16.1000508@zafena.se>
Im just pinging this patch, I am looking for someone with access to the
correct autotools to test the patch and to regenerate the configure script.
Thanks!
Xerxes R?nby skrev:
> The current llvm-config suggests the Interpreter on ARM when running
> llvm-config --libs engine
>
> $ llvm-config --libs engine
> -lLLVMInterpreter -lLLVMExecutionEngine -lLLVMCodeGen -lLLVMScalarOpts
> -lLLVMTransformUtils -lLLVMipa -lLLVMAnalysis -lLLVMTarget -lLLVMMC
> -lLLVMCore -lLLVMSupport -lLLVMSystem
>
> expected result would be to output the JIT instead of the Interpreter:
>
> $ llvm-config --libs engine
> -lLLVMARMAsmPrinter -lLLVMARMCodeGen -lLLVMSelectionDAG -lLLVMAsmPrinter
> -lLLVMARMInfo -lLLVMJIT -lLLVMExecutionEngine -lLLVMCodeGen
> -lLLVMScalarOpts -lLLVMTransformUtils -lLLVMipa -lLLVMAnalysis
> -lLLVMTarget -lLLVMMC -lLLVMCore -lLLVMSupport -lLLVMSystem
>
> The attached patch fixes this issue.
> I need someone to commit this for me since the configure script needs
> regenerating from configure.ac with some specific version of autotools.
>
> Cheers
> Xerxes
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From baldrick at free.fr Mon Sep 14 08:39:42 2009
From: baldrick at free.fr (Duncan Sands)
Date: Mon, 14 Sep 2009 13:39:42 -0000
Subject: [llvm-commits] [gcc-plugin] r81761 - /gcc-plugin/trunk/Makefile
Message-ID: <200909141339.n8EDdguo004107@zion.cs.uiuc.edu>
Author: baldrick
Date: Mon Sep 14 08:39:42 2009
New Revision: 81761
URL: http://llvm.org/viewvc/llvm-project?rev=81761&view=rev
Log:
Correct a build dependency.
Modified:
gcc-plugin/trunk/Makefile
Modified: gcc-plugin/trunk/Makefile
URL: http://llvm.org/viewvc/llvm-project/gcc-plugin/trunk/Makefile?rev=81761&r1=81760&r2=81761&view=diff
==============================================================================
--- gcc-plugin/trunk/Makefile (original)
+++ gcc-plugin/trunk/Makefile Mon Sep 14 08:39:42 2009
@@ -30,7 +30,7 @@
llvm.so: $(PLUGIN_OBJECT_FILES)
$(CXX) -shared $^ -o $@ $(LDFLAGS)
-llvm-cache.c: gt-llvm-cache.h
+llvm-cache.o: gt-llvm-cache.h
gt-llvm-cache.h:
cd $(GCCOBJECT_DIR)/gcc && ./build/gengtype \
From baldrick at free.fr Mon Sep 14 08:54:33 2009
From: baldrick at free.fr (Duncan Sands)
Date: Mon, 14 Sep 2009 13:54:33 -0000
Subject: [llvm-commits] [gcc-plugin] r81762 - in /gcc-plugin/trunk: ./
gt-llvm-cache.h
Message-ID: <200909141354.n8EDsYnw006148@zion.cs.uiuc.edu>
Author: baldrick
Date: Mon Sep 14 08:54:33 2009
New Revision: 81762
URL: http://llvm.org/viewvc/llvm-project?rev=81762&view=rev
Log:
The generated header containing garbage collector information
is actually not host or target specific as far as I can see.
Add it to the repository so everyone doesn't have to generate
it (which requires a big gcc patch).
Added:
gcc-plugin/trunk/gt-llvm-cache.h
Modified:
gcc-plugin/trunk/ (props changed)
Propchange: gcc-plugin/trunk/
------------------------------------------------------------------------------
--- svn:ignore (original)
+++ svn:ignore (removed)
@@ -1 +0,0 @@
-gt-llvm-cache.h
Added: gcc-plugin/trunk/gt-llvm-cache.h
URL: http://llvm.org/viewvc/llvm-project/gcc-plugin/trunk/gt-llvm-cache.h?rev=81762&view=auto
==============================================================================
--- gcc-plugin/trunk/gt-llvm-cache.h (added)
+++ gcc-plugin/trunk/gt-llvm-cache.h Mon Sep 14 08:54:33 2009
@@ -0,0 +1,1962 @@
+/* Type information for GCC.
+ Copyright (C) 2004, 2007, 2009 Free Software Foundation, Inc.
+
+This file is part of GCC.
+
+GCC is free software; you can redistribute it and/or modify it under
+the terms of the GNU General Public License as published by the Free
+Software Foundation; either version 3, or (at your option) any later
+version.
+
+GCC is distributed in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or
+FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+for more details.
+
+You should have received a copy of the GNU General Public License
+along with GCC; see the file COPYING3. If not see
+. */
+
+/* This file is machine generated. Do not edit. */
+
+/* Dynamic enumeration of plugin types. */
+#ifdef GCC_PLUGIN_HAVE_PCH
+static int gccplugin_type_base;
+#define gt_ggc_e_13tree_llvm_map ((gccplugin_type_base>0)?(gccplugin_type_base+0):0)
+#define gt_e_P13tree_llvm_map4htab ((gccplugin_type_base>0)?(gccplugin_type_base+1):0)
+
+#define GCCPLUGIN_TYPE_COUNT 2
+/* end ifdef GCC_PLUGIN_HAVE_PCH */
+#endif
+
+/* GC marker procedures. */
+#define gt_ggc_m_13tree_llvm_map(X) do { \
+ if (X != NULL) gt_ggc_mx_tree_llvm_map (X);\
+ } while (0)
+extern void gt_ggc_mx_tree_llvm_map (void *);
+#define gt_ggc_m_15interface_tuple(X) do { \
+ if (X != NULL) gt_ggc_mx_interface_tuple (X);\
+ } while (0)
+extern void gt_ggc_mx_interface_tuple (void *);
+#define gt_ggc_m_16volatilized_type(X) do { \
+ if (X != NULL) gt_ggc_mx_volatilized_type (X);\
+ } while (0)
+extern void gt_ggc_mx_volatilized_type (void *);
+#define gt_ggc_m_17string_descriptor(X) do { \
+ if (X != NULL) gt_ggc_mx_string_descriptor (X);\
+ } while (0)
+extern void gt_ggc_mx_string_descriptor (void *);
+#define gt_ggc_m_15c_inline_static(X) do { \
+ if (X != NULL) gt_ggc_mx_c_inline_static (X);\
+ } while (0)
+extern void gt_ggc_mx_c_inline_static (void *);
+#define gt_ggc_m_24VEC_c_goto_bindings_p_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_c_goto_bindings_p_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_c_goto_bindings_p_gc (void *);
+#define gt_ggc_m_15c_goto_bindings(X) do { \
+ if (X != NULL) gt_ggc_mx_c_goto_bindings (X);\
+ } while (0)
+extern void gt_ggc_mx_c_goto_bindings (void *);
+#define gt_ggc_m_7c_scope(X) do { \
+ if (X != NULL) gt_ggc_mx_c_scope (X);\
+ } while (0)
+extern void gt_ggc_mx_c_scope (void *);
+#define gt_ggc_m_9c_binding(X) do { \
+ if (X != NULL) gt_ggc_mx_c_binding (X);\
+ } while (0)
+extern void gt_ggc_mx_c_binding (void *);
+#define gt_ggc_m_12c_label_vars(X) do { \
+ if (X != NULL) gt_ggc_mx_c_label_vars (X);\
+ } while (0)
+extern void gt_ggc_mx_c_label_vars (void *);
+#define gt_ggc_m_8c_parser(X) do { \
+ if (X != NULL) gt_ggc_mx_c_parser (X);\
+ } while (0)
+extern void gt_ggc_mx_c_parser (void *);
+#define gt_ggc_m_9imp_entry(X) do { \
+ if (X != NULL) gt_ggc_mx_imp_entry (X);\
+ } while (0)
+extern void gt_ggc_mx_imp_entry (void *);
+#define gt_ggc_m_16hashed_attribute(X) do { \
+ if (X != NULL) gt_ggc_mx_hashed_attribute (X);\
+ } while (0)
+extern void gt_ggc_mx_hashed_attribute (void *);
+#define gt_ggc_m_12hashed_entry(X) do { \
+ if (X != NULL) gt_ggc_mx_hashed_entry (X);\
+ } while (0)
+extern void gt_ggc_mx_hashed_entry (void *);
+#define gt_ggc_m_14type_assertion(X) do { \
+ if (X != NULL) gt_ggc_mx_type_assertion (X);\
+ } while (0)
+extern void gt_ggc_mx_type_assertion (void *);
+#define gt_ggc_m_18treetreehash_entry(X) do { \
+ if (X != NULL) gt_ggc_mx_treetreehash_entry (X);\
+ } while (0)
+extern void gt_ggc_mx_treetreehash_entry (void *);
+#define gt_ggc_m_5CPool(X) do { \
+ if (X != NULL) gt_ggc_mx_CPool (X);\
+ } while (0)
+extern void gt_ggc_mx_CPool (void *);
+#define gt_ggc_m_3JCF(X) do { \
+ if (X != NULL) gt_ggc_mx_JCF (X);\
+ } while (0)
+extern void gt_ggc_mx_JCF (void *);
+#define gt_ggc_m_17module_htab_entry(X) do { \
+ if (X != NULL) gt_ggc_mx_module_htab_entry (X);\
+ } while (0)
+extern void gt_ggc_mx_module_htab_entry (void *);
+#define gt_ggc_m_13binding_level(X) do { \
+ if (X != NULL) gt_ggc_mx_binding_level (X);\
+ } while (0)
+extern void gt_ggc_mx_binding_level (void *);
+#define gt_ggc_m_9opt_stack(X) do { \
+ if (X != NULL) gt_ggc_mx_opt_stack (X);\
+ } while (0)
+extern void gt_ggc_mx_opt_stack (void *);
+#define gt_ggc_m_16def_pragma_macro(X) do { \
+ if (X != NULL) gt_ggc_mx_def_pragma_macro (X);\
+ } while (0)
+extern void gt_ggc_mx_def_pragma_macro (void *);
+#define gt_ggc_m_22def_pragma_macro_value(X) do { \
+ if (X != NULL) gt_ggc_mx_def_pragma_macro_value (X);\
+ } while (0)
+extern void gt_ggc_mx_def_pragma_macro_value (void *);
+#define gt_ggc_m_11align_stack(X) do { \
+ if (X != NULL) gt_ggc_mx_align_stack (X);\
+ } while (0)
+extern void gt_ggc_mx_align_stack (void *);
+#define gt_ggc_m_18VEC_tree_gc_vec_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_tree_gc_vec_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_tree_gc_vec_gc (void *);
+#define gt_ggc_m_19VEC_const_char_p_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_const_char_p_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_const_char_p_gc (void *);
+#define gt_ggc_m_21pending_abstract_type(X) do { \
+ if (X != NULL) gt_ggc_mx_pending_abstract_type (X);\
+ } while (0)
+extern void gt_ggc_mx_pending_abstract_type (void *);
+#define gt_ggc_m_9cp_parser(X) do { \
+ if (X != NULL) gt_ggc_mx_cp_parser (X);\
+ } while (0)
+extern void gt_ggc_mx_cp_parser (void *);
+#define gt_ggc_m_17cp_parser_context(X) do { \
+ if (X != NULL) gt_ggc_mx_cp_parser_context (X);\
+ } while (0)
+extern void gt_ggc_mx_cp_parser_context (void *);
+#define gt_ggc_m_8cp_lexer(X) do { \
+ if (X != NULL) gt_ggc_mx_cp_lexer (X);\
+ } while (0)
+extern void gt_ggc_mx_cp_lexer (void *);
+#define gt_ggc_m_10tree_check(X) do { \
+ if (X != NULL) gt_ggc_mx_tree_check (X);\
+ } while (0)
+extern void gt_ggc_mx_tree_check (void *);
+#define gt_ggc_m_22VEC_deferred_access_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_deferred_access_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_deferred_access_gc (void *);
+#define gt_ggc_m_10spec_entry(X) do { \
+ if (X != NULL) gt_ggc_mx_spec_entry (X);\
+ } while (0)
+extern void gt_ggc_mx_spec_entry (void *);
+#define gt_ggc_m_16pending_template(X) do { \
+ if (X != NULL) gt_ggc_mx_pending_template (X);\
+ } while (0)
+extern void gt_ggc_mx_pending_template (void *);
+#define gt_ggc_m_21named_label_use_entry(X) do { \
+ if (X != NULL) gt_ggc_mx_named_label_use_entry (X);\
+ } while (0)
+extern void gt_ggc_mx_named_label_use_entry (void *);
+#define gt_ggc_m_28VEC_deferred_access_check_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_deferred_access_check_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_deferred_access_check_gc (void *);
+#define gt_ggc_m_11tinst_level(X) do { \
+ if (X != NULL) gt_ggc_mx_tinst_level (X);\
+ } while (0)
+extern void gt_ggc_mx_tinst_level (void *);
+#define gt_ggc_m_18sorted_fields_type(X) do { \
+ if (X != NULL) gt_ggc_mx_sorted_fields_type (X);\
+ } while (0)
+extern void gt_ggc_mx_sorted_fields_type (void *);
+#define gt_ggc_m_18VEC_tree_pair_s_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_tree_pair_s_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_tree_pair_s_gc (void *);
+#define gt_ggc_m_17named_label_entry(X) do { \
+ if (X != NULL) gt_ggc_mx_named_label_entry (X);\
+ } while (0)
+extern void gt_ggc_mx_named_label_entry (void *);
+#define gt_ggc_m_14cp_token_cache(X) do { \
+ if (X != NULL) gt_ggc_mx_cp_token_cache (X);\
+ } while (0)
+extern void gt_ggc_mx_cp_token_cache (void *);
+#define gt_ggc_m_11saved_scope(X) do { \
+ if (X != NULL) gt_ggc_mx_saved_scope (X);\
+ } while (0)
+extern void gt_ggc_mx_saved_scope (void *);
+#define gt_ggc_m_16cxx_int_tree_map(X) do { \
+ if (X != NULL) gt_ggc_mx_cxx_int_tree_map (X);\
+ } while (0)
+extern void gt_ggc_mx_cxx_int_tree_map (void *);
+#define gt_ggc_m_23VEC_cp_class_binding_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_cp_class_binding_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_cp_class_binding_gc (void *);
+#define gt_ggc_m_24VEC_cxx_saved_binding_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_cxx_saved_binding_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_cxx_saved_binding_gc (void *);
+#define gt_ggc_m_16cp_binding_level(X) do { \
+ if (X != NULL) gt_ggc_mx_cp_binding_level (X);\
+ } while (0)
+extern void gt_ggc_mx_cp_binding_level (void *);
+#define gt_ggc_m_11cxx_binding(X) do { \
+ if (X != NULL) gt_ggc_mx_cxx_binding (X);\
+ } while (0)
+extern void gt_ggc_mx_cxx_binding (void *);
+#define gt_ggc_m_15binding_entry_s(X) do { \
+ if (X != NULL) gt_ggc_mx_binding_entry_s (X);\
+ } while (0)
+extern void gt_ggc_mx_binding_entry_s (void *);
+#define gt_ggc_m_15binding_table_s(X) do { \
+ if (X != NULL) gt_ggc_mx_binding_table_s (X);\
+ } while (0)
+extern void gt_ggc_mx_binding_table_s (void *);
+#define gt_ggc_m_14VEC_tinfo_s_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_tinfo_s_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_tinfo_s_gc (void *);
+#define gt_ggc_m_18gnat_binding_level(X) do { \
+ if (X != NULL) gt_ggc_mx_gnat_binding_level (X);\
+ } while (0)
+extern void gt_ggc_mx_gnat_binding_level (void *);
+#define gt_ggc_m_9elab_info(X) do { \
+ if (X != NULL) gt_ggc_mx_elab_info (X);\
+ } while (0)
+extern void gt_ggc_mx_elab_info (void *);
+#define gt_ggc_m_10stmt_group(X) do { \
+ if (X != NULL) gt_ggc_mx_stmt_group (X);\
+ } while (0)
+extern void gt_ggc_mx_stmt_group (void *);
+#define gt_ggc_m_16VEC_parm_attr_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_parm_attr_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_parm_attr_gc (void *);
+#define gt_ggc_m_11parm_attr_d(X) do { \
+ if (X != NULL) gt_ggc_mx_parm_attr_d (X);\
+ } while (0)
+extern void gt_ggc_mx_parm_attr_d (void *);
+#define gt_ggc_m_19lto_symtab_decl_def(X) do { \
+ if (X != NULL) gt_ggc_mx_lto_symtab_decl_def (X);\
+ } while (0)
+extern void gt_ggc_mx_lto_symtab_decl_def (void *);
+#define gt_ggc_m_25lto_symtab_identifier_def(X) do { \
+ if (X != NULL) gt_ggc_mx_lto_symtab_identifier_def (X);\
+ } while (0)
+extern void gt_ggc_mx_lto_symtab_identifier_def (void *);
+#define gt_ggc_m_20ssa_operand_memory_d(X) do { \
+ if (X != NULL) gt_ggc_mx_ssa_operand_memory_d (X);\
+ } while (0)
+extern void gt_ggc_mx_ssa_operand_memory_d (void *);
+#define gt_ggc_m_13scev_info_str(X) do { \
+ if (X != NULL) gt_ggc_mx_scev_info_str (X);\
+ } while (0)
+extern void gt_ggc_mx_scev_info_str (void *);
+#define gt_ggc_m_13VEC_gimple_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_gimple_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_gimple_gc (void *);
+#define gt_ggc_m_9type_hash(X) do { \
+ if (X != NULL) gt_ggc_mx_type_hash (X);\
+ } while (0)
+extern void gt_ggc_mx_type_hash (void *);
+#define gt_ggc_m_16string_pool_data(X) do { \
+ if (X != NULL) gt_ggc_mx_string_pool_data (X);\
+ } while (0)
+extern void gt_ggc_mx_string_pool_data (void *);
+#define gt_ggc_m_13libfunc_entry(X) do { \
+ if (X != NULL) gt_ggc_mx_libfunc_entry (X);\
+ } while (0)
+extern void gt_ggc_mx_libfunc_entry (void *);
+#define gt_ggc_m_23temp_slot_address_entry(X) do { \
+ if (X != NULL) gt_ggc_mx_temp_slot_address_entry (X);\
+ } while (0)
+extern void gt_ggc_mx_temp_slot_address_entry (void *);
+#define gt_ggc_m_15throw_stmt_node(X) do { \
+ if (X != NULL) gt_ggc_mx_throw_stmt_node (X);\
+ } while (0)
+extern void gt_ggc_mx_throw_stmt_node (void *);
+#define gt_ggc_m_16VEC_eh_region_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_eh_region_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_eh_region_gc (void *);
+#define gt_ggc_m_11eh_region_d(X) do { \
+ if (X != NULL) gt_ggc_mx_eh_region_d (X);\
+ } while (0)
+extern void gt_ggc_mx_eh_region_d (void *);
+#define gt_ggc_m_16var_loc_list_def(X) do { \
+ if (X != NULL) gt_ggc_mx_var_loc_list_def (X);\
+ } while (0)
+extern void gt_ggc_mx_var_loc_list_def (void *);
+#define gt_ggc_m_12var_loc_node(X) do { \
+ if (X != NULL) gt_ggc_mx_var_loc_node (X);\
+ } while (0)
+extern void gt_ggc_mx_var_loc_node (void *);
+#define gt_ggc_m_20VEC_die_arg_entry_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_die_arg_entry_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_die_arg_entry_gc (void *);
+#define gt_ggc_m_16limbo_die_struct(X) do { \
+ if (X != NULL) gt_ggc_mx_limbo_die_struct (X);\
+ } while (0)
+extern void gt_ggc_mx_limbo_die_struct (void *);
+#define gt_ggc_m_20VEC_pubname_entry_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_pubname_entry_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_pubname_entry_gc (void *);
+#define gt_ggc_m_19VEC_dw_attr_node_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_dw_attr_node_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_dw_attr_node_gc (void *);
+#define gt_ggc_m_25dw_ranges_by_label_struct(X) do { \
+ if (X != NULL) gt_ggc_mx_dw_ranges_by_label_struct (X);\
+ } while (0)
+extern void gt_ggc_mx_dw_ranges_by_label_struct (void *);
+#define gt_ggc_m_16dw_ranges_struct(X) do { \
+ if (X != NULL) gt_ggc_mx_dw_ranges_struct (X);\
+ } while (0)
+extern void gt_ggc_mx_dw_ranges_struct (void *);
+#define gt_ggc_m_28dw_separate_line_info_struct(X) do { \
+ if (X != NULL) gt_ggc_mx_dw_separate_line_info_struct (X);\
+ } while (0)
+extern void gt_ggc_mx_dw_separate_line_info_struct (void *);
+#define gt_ggc_m_19dw_line_info_struct(X) do { \
+ if (X != NULL) gt_ggc_mx_dw_line_info_struct (X);\
+ } while (0)
+extern void gt_ggc_mx_dw_line_info_struct (void *);
+#define gt_ggc_m_25VEC_deferred_locations_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_deferred_locations_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_deferred_locations_gc (void *);
+#define gt_ggc_m_18dw_loc_list_struct(X) do { \
+ if (X != NULL) gt_ggc_mx_dw_loc_list_struct (X);\
+ } while (0)
+extern void gt_ggc_mx_dw_loc_list_struct (void *);
+#define gt_ggc_m_15dwarf_file_data(X) do { \
+ if (X != NULL) gt_ggc_mx_dwarf_file_data (X);\
+ } while (0)
+extern void gt_ggc_mx_dwarf_file_data (void *);
+#define gt_ggc_m_15queued_reg_save(X) do { \
+ if (X != NULL) gt_ggc_mx_queued_reg_save (X);\
+ } while (0)
+extern void gt_ggc_mx_queued_reg_save (void *);
+#define gt_ggc_m_20indirect_string_node(X) do { \
+ if (X != NULL) gt_ggc_mx_indirect_string_node (X);\
+ } while (0)
+extern void gt_ggc_mx_indirect_string_node (void *);
+#define gt_ggc_m_19dw_loc_descr_struct(X) do { \
+ if (X != NULL) gt_ggc_mx_dw_loc_descr_struct (X);\
+ } while (0)
+extern void gt_ggc_mx_dw_loc_descr_struct (void *);
+#define gt_ggc_m_13dw_fde_struct(X) do { \
+ if (X != NULL) gt_ggc_mx_dw_fde_struct (X);\
+ } while (0)
+extern void gt_ggc_mx_dw_fde_struct (void *);
+#define gt_ggc_m_13dw_cfi_struct(X) do { \
+ if (X != NULL) gt_ggc_mx_dw_cfi_struct (X);\
+ } while (0)
+extern void gt_ggc_mx_dw_cfi_struct (void *);
+#define gt_ggc_m_8typeinfo(X) do { \
+ if (X != NULL) gt_ggc_mx_typeinfo (X);\
+ } while (0)
+extern void gt_ggc_mx_typeinfo (void *);
+#define gt_ggc_m_22VEC_alias_set_entry_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_alias_set_entry_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_alias_set_entry_gc (void *);
+#define gt_ggc_m_17alias_set_entry_d(X) do { \
+ if (X != NULL) gt_ggc_mx_alias_set_entry_d (X);\
+ } while (0)
+extern void gt_ggc_mx_alias_set_entry_d (void *);
+#define gt_ggc_m_24constant_descriptor_tree(X) do { \
+ if (X != NULL) gt_ggc_mx_constant_descriptor_tree (X);\
+ } while (0)
+extern void gt_ggc_mx_constant_descriptor_tree (void *);
+#define gt_ggc_m_15cgraph_asm_node(X) do { \
+ if (X != NULL) gt_ggc_mx_cgraph_asm_node (X);\
+ } while (0)
+extern void gt_ggc_mx_cgraph_asm_node (void *);
+#define gt_ggc_m_12varpool_node(X) do { \
+ if (X != NULL) gt_ggc_mx_varpool_node (X);\
+ } while (0)
+extern void gt_ggc_mx_varpool_node (void *);
+#define gt_ggc_m_22VEC_cgraph_node_set_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_cgraph_node_set_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_cgraph_node_set_gc (void *);
+#define gt_ggc_m_19cgraph_node_set_def(X) do { \
+ if (X != NULL) gt_ggc_mx_cgraph_node_set_def (X);\
+ } while (0)
+extern void gt_ggc_mx_cgraph_node_set_def (void *);
+#define gt_ggc_m_27cgraph_node_set_element_def(X) do { \
+ if (X != NULL) gt_ggc_mx_cgraph_node_set_element_def (X);\
+ } while (0)
+extern void gt_ggc_mx_cgraph_node_set_element_def (void *);
+#define gt_ggc_m_22VEC_cgraph_node_ptr_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_cgraph_node_ptr_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_cgraph_node_ptr_gc (void *);
+#define gt_ggc_m_11cgraph_edge(X) do { \
+ if (X != NULL) gt_ggc_mx_cgraph_edge (X);\
+ } while (0)
+extern void gt_ggc_mx_cgraph_edge (void *);
+#define gt_ggc_m_24VEC_ipa_replace_map_p_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_ipa_replace_map_p_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_ipa_replace_map_p_gc (void *);
+#define gt_ggc_m_15ipa_replace_map(X) do { \
+ if (X != NULL) gt_ggc_mx_ipa_replace_map (X);\
+ } while (0)
+extern void gt_ggc_mx_ipa_replace_map (void *);
+#define gt_ggc_m_11cgraph_node(X) do { \
+ if (X != NULL) gt_ggc_mx_cgraph_node (X);\
+ } while (0)
+extern void gt_ggc_mx_cgraph_node (void *);
+#define gt_ggc_m_18VEC_basic_block_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_basic_block_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_basic_block_gc (void *);
+#define gt_ggc_m_14gimple_bb_info(X) do { \
+ if (X != NULL) gt_ggc_mx_gimple_bb_info (X);\
+ } while (0)
+extern void gt_ggc_mx_gimple_bb_info (void *);
+#define gt_ggc_m_11rtl_bb_info(X) do { \
+ if (X != NULL) gt_ggc_mx_rtl_bb_info (X);\
+ } while (0)
+extern void gt_ggc_mx_rtl_bb_info (void *);
+#define gt_ggc_m_11VEC_edge_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_edge_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_edge_gc (void *);
+#define gt_ggc_m_17cselib_val_struct(X) do { \
+ if (X != NULL) gt_ggc_mx_cselib_val_struct (X);\
+ } while (0)
+extern void gt_ggc_mx_cselib_val_struct (void *);
+#define gt_ggc_m_12elt_loc_list(X) do { \
+ if (X != NULL) gt_ggc_mx_elt_loc_list (X);\
+ } while (0)
+extern void gt_ggc_mx_elt_loc_list (void *);
+#define gt_ggc_m_13VEC_loop_p_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_loop_p_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_loop_p_gc (void *);
+#define gt_ggc_m_4loop(X) do { \
+ if (X != NULL) gt_ggc_mx_loop (X);\
+ } while (0)
+extern void gt_ggc_mx_loop (void *);
+#define gt_ggc_m_9loop_exit(X) do { \
+ if (X != NULL) gt_ggc_mx_loop_exit (X);\
+ } while (0)
+extern void gt_ggc_mx_loop_exit (void *);
+#define gt_ggc_m_13nb_iter_bound(X) do { \
+ if (X != NULL) gt_ggc_mx_nb_iter_bound (X);\
+ } while (0)
+extern void gt_ggc_mx_nb_iter_bound (void *);
+#define gt_ggc_m_17language_function(X) do { \
+ if (X != NULL) gt_ggc_mx_language_function (X);\
+ } while (0)
+extern void gt_ggc_mx_language_function (void *);
+#define gt_ggc_m_5loops(X) do { \
+ if (X != NULL) gt_ggc_mx_loops (X);\
+ } while (0)
+extern void gt_ggc_mx_loops (void *);
+#define gt_ggc_m_18control_flow_graph(X) do { \
+ if (X != NULL) gt_ggc_mx_control_flow_graph (X);\
+ } while (0)
+extern void gt_ggc_mx_control_flow_graph (void *);
+#define gt_ggc_m_9eh_status(X) do { \
+ if (X != NULL) gt_ggc_mx_eh_status (X);\
+ } while (0)
+extern void gt_ggc_mx_eh_status (void *);
+#define gt_ggc_m_20initial_value_struct(X) do { \
+ if (X != NULL) gt_ggc_mx_initial_value_struct (X);\
+ } while (0)
+extern void gt_ggc_mx_initial_value_struct (void *);
+#define gt_ggc_m_17rtx_constant_pool(X) do { \
+ if (X != NULL) gt_ggc_mx_rtx_constant_pool (X);\
+ } while (0)
+extern void gt_ggc_mx_rtx_constant_pool (void *);
+#define gt_ggc_m_18VEC_temp_slot_p_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_temp_slot_p_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_temp_slot_p_gc (void *);
+#define gt_ggc_m_9temp_slot(X) do { \
+ if (X != NULL) gt_ggc_mx_temp_slot (X);\
+ } while (0)
+extern void gt_ggc_mx_temp_slot (void *);
+#define gt_ggc_m_9gimple_df(X) do { \
+ if (X != NULL) gt_ggc_mx_gimple_df (X);\
+ } while (0)
+extern void gt_ggc_mx_gimple_df (void *);
+#define gt_ggc_m_23VEC_call_site_record_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_call_site_record_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_call_site_record_gc (void *);
+#define gt_ggc_m_18call_site_record_d(X) do { \
+ if (X != NULL) gt_ggc_mx_call_site_record_d (X);\
+ } while (0)
+extern void gt_ggc_mx_call_site_record_d (void *);
+#define gt_ggc_m_14sequence_stack(X) do { \
+ if (X != NULL) gt_ggc_mx_sequence_stack (X);\
+ } while (0)
+extern void gt_ggc_mx_sequence_stack (void *);
+#define gt_ggc_m_8elt_list(X) do { \
+ if (X != NULL) gt_ggc_mx_elt_list (X);\
+ } while (0)
+extern void gt_ggc_mx_elt_list (void *);
+#define gt_ggc_m_17tree_priority_map(X) do { \
+ if (X != NULL) gt_ggc_mx_tree_priority_map (X);\
+ } while (0)
+extern void gt_ggc_mx_tree_priority_map (void *);
+#define gt_ggc_m_12tree_int_map(X) do { \
+ if (X != NULL) gt_ggc_mx_tree_int_map (X);\
+ } while (0)
+extern void gt_ggc_mx_tree_int_map (void *);
+#define gt_ggc_m_8tree_map(X) do { \
+ if (X != NULL) gt_ggc_mx_tree_map (X);\
+ } while (0)
+extern void gt_ggc_mx_tree_map (void *);
+#define gt_ggc_m_14lang_tree_node(X) do { \
+ if (X != NULL) gt_ggc_mx_lang_tree_node (X);\
+ } while (0)
+extern void gt_ggc_mx_lang_tree_node (void *);
+#define gt_ggc_m_24tree_statement_list_node(X) do { \
+ if (X != NULL) gt_ggc_mx_tree_statement_list_node (X);\
+ } while (0)
+extern void gt_ggc_mx_tree_statement_list_node (void *);
+#define gt_ggc_m_9lang_decl(X) do { \
+ if (X != NULL) gt_ggc_mx_lang_decl (X);\
+ } while (0)
+extern void gt_ggc_mx_lang_decl (void *);
+#define gt_ggc_m_9lang_type(X) do { \
+ if (X != NULL) gt_ggc_mx_lang_type (X);\
+ } while (0)
+extern void gt_ggc_mx_lang_type (void *);
+#define gt_ggc_m_10die_struct(X) do { \
+ if (X != NULL) gt_ggc_mx_die_struct (X);\
+ } while (0)
+extern void gt_ggc_mx_die_struct (void *);
+#define gt_ggc_m_15varray_head_tag(X) do { \
+ if (X != NULL) gt_ggc_mx_varray_head_tag (X);\
+ } while (0)
+extern void gt_ggc_mx_varray_head_tag (void *);
+#define gt_ggc_m_12ptr_info_def(X) do { \
+ if (X != NULL) gt_ggc_mx_ptr_info_def (X);\
+ } while (0)
+extern void gt_ggc_mx_ptr_info_def (void *);
+#define gt_ggc_m_22VEC_constructor_elt_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_constructor_elt_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_constructor_elt_gc (void *);
+#define gt_ggc_m_10tree_ann_d(X) do { \
+ if (X != NULL) gt_ggc_mx_tree_ann_d (X);\
+ } while (0)
+extern void gt_ggc_mx_tree_ann_d (void *);
+#define gt_ggc_m_17VEC_alias_pair_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_alias_pair_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_alias_pair_gc (void *);
+#define gt_ggc_m_11VEC_tree_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_tree_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_tree_gc (void *);
+#define gt_ggc_m_8function(X) do { \
+ if (X != NULL) gt_ggc_mx_function (X);\
+ } while (0)
+extern void gt_ggc_mx_function (void *);
+#define gt_ggc_m_23constant_descriptor_rtx(X) do { \
+ if (X != NULL) gt_ggc_mx_constant_descriptor_rtx (X);\
+ } while (0)
+extern void gt_ggc_mx_constant_descriptor_rtx (void *);
+#define gt_ggc_m_11fixed_value(X) do { \
+ if (X != NULL) gt_ggc_mx_fixed_value (X);\
+ } while (0)
+extern void gt_ggc_mx_fixed_value (void *);
+#define gt_ggc_m_10real_value(X) do { \
+ if (X != NULL) gt_ggc_mx_real_value (X);\
+ } while (0)
+extern void gt_ggc_mx_real_value (void *);
+#define gt_ggc_m_10VEC_rtx_gc(X) do { \
+ if (X != NULL) gt_ggc_mx_VEC_rtx_gc (X);\
+ } while (0)
+extern void gt_ggc_mx_VEC_rtx_gc (void *);
+#define gt_ggc_m_12object_block(X) do { \
+ if (X != NULL) gt_ggc_mx_object_block (X);\
+ } while (0)
+extern void gt_ggc_mx_object_block (void *);
+#define gt_ggc_m_9reg_attrs(X) do { \
+ if (X != NULL) gt_ggc_mx_reg_attrs (X);\
+ } while (0)
+extern void gt_ggc_mx_reg_attrs (void *);
+#define gt_ggc_m_9mem_attrs(X) do { \
+ if (X != NULL) gt_ggc_mx_mem_attrs (X);\
+ } while (0)
+extern void gt_ggc_mx_mem_attrs (void *);
+#define gt_ggc_m_14bitmap_obstack(X) do { \
+ if (X != NULL) gt_ggc_mx_bitmap_obstack (X);\
+ } while (0)
+extern void gt_ggc_mx_bitmap_obstack (void *);
+#define gt_ggc_m_18bitmap_element_def(X) do { \
+ if (X != NULL) gt_ggc_mx_bitmap_element_def (X);\
+ } while (0)
+extern void gt_ggc_mx_bitmap_element_def (void *);
+#define gt_ggc_m_16machine_function(X) do { \
+ if (X != NULL) gt_ggc_mx_machine_function (X);\
+ } while (0)
+extern void gt_ggc_mx_machine_function (void *);
+#define gt_ggc_m_17stack_local_entry(X) do { \
+ if (X != NULL) gt_ggc_mx_stack_local_entry (X);\
+ } while (0)
+extern void gt_ggc_mx_stack_local_entry (void *);
+#define gt_ggc_m_15basic_block_def(X) do { \
+ if (X != NULL) gt_ggc_mx_basic_block_def (X);\
+ } while (0)
+extern void gt_ggc_mx_basic_block_def (void *);
+#define gt_ggc_m_8edge_def(X) do { \
+ if (X != NULL) gt_ggc_mx_edge_def (X);\
+ } while (0)
+extern void gt_ggc_mx_edge_def (void *);
+#define gt_ggc_m_17gimple_seq_node_d(X) do { \
+ if (X != NULL) gt_ggc_mx_gimple_seq_node_d (X);\
+ } while (0)
+extern void gt_ggc_mx_gimple_seq_node_d (void *);
+#define gt_ggc_m_12gimple_seq_d(X) do { \
+ if (X != NULL) gt_ggc_mx_gimple_seq_d (X);\
+ } while (0)
+extern void gt_ggc_mx_gimple_seq_d (void *);
+#define gt_ggc_m_7section(X) do { \
+ if (X != NULL) gt_ggc_mx_section (X);\
+ } while (0)
+extern void gt_ggc_mx_section (void *);
+#define gt_ggc_m_18gimple_statement_d(X) do { \
+ if (X != NULL) gt_ggc_mx_gimple_statement_d (X);\
+ } while (0)
+extern void gt_ggc_mx_gimple_statement_d (void *);
+#define gt_ggc_m_9rtvec_def(X) do { \
+ if (X != NULL) gt_ggc_mx_rtvec_def (X);\
+ } while (0)
+extern void gt_ggc_mx_rtvec_def (void *);
+#define gt_ggc_m_7rtx_def(X) do { \
+ if (X != NULL) gt_ggc_mx_rtx_def (X);\
+ } while (0)
+extern void gt_ggc_mx_rtx_def (void *);
+#define gt_ggc_m_15bitmap_head_def(X) do { \
+ if (X != NULL) gt_ggc_mx_bitmap_head_def (X);\
+ } while (0)
+extern void gt_ggc_mx_bitmap_head_def (void *);
+#define gt_ggc_m_9tree_node(X) do { \
+ if (X != NULL) gt_ggc_mx_tree_node (X);\
+ } while (0)
+#define gt_ggc_mx_tree_node gt_ggc_mx_lang_tree_node
+#define gt_ggc_m_6answer(X) do { \
+ if (X != NULL) gt_ggc_mx_answer (X);\
+ } while (0)
+extern void gt_ggc_mx_answer (void *);
+#define gt_ggc_m_9cpp_macro(X) do { \
+ if (X != NULL) gt_ggc_mx_cpp_macro (X);\
+ } while (0)
+extern void gt_ggc_mx_cpp_macro (void *);
+#define gt_ggc_m_9cpp_token(X) do { \
+ if (X != NULL) gt_ggc_mx_cpp_token (X);\
+ } while (0)
+extern void gt_ggc_mx_cpp_token (void *);
+#define gt_ggc_m_9line_maps(X) do { \
+ if (X != NULL) gt_ggc_mx_line_maps (X);\
+ } while (0)
+extern void gt_ggc_mx_line_maps (void *);
+extern void gt_ggc_m_II17splay_tree_node_s (void *);
+extern void gt_ggc_m_SP9tree_node17splay_tree_node_s (void *);
+extern void gt_ggc_m_P9tree_nodeP9tree_node17splay_tree_node_s (void *);
+extern void gt_ggc_m_IP9tree_node17splay_tree_node_s (void *);
+extern void gt_ggc_m_P13tree_llvm_map4htab (void *);
+
+void
+gt_ggc_m_P13tree_llvm_map4htab (void *x_p)
+{
+ struct htab * const x = (struct htab *)x_p;
+ if (ggc_test_and_set_mark (x))
+ {
+ if ((*x).entries != NULL) {
+ size_t i0;
+ for (i0 = 0; i0 != (size_t)(((*x)).size); i0++) {
+ gt_ggc_m_13tree_llvm_map ((*x).entries[i0]);
+ }
+ ggc_mark ((*x).entries);
+ }
+ }
+}
+extern void gt_ggc_m_P15interface_tuple4htab (void *);
+extern void gt_ggc_m_P16volatilized_type4htab (void *);
+extern void gt_ggc_m_P17string_descriptor4htab (void *);
+extern void gt_ggc_m_P14type_assertion4htab (void *);
+extern void gt_ggc_m_P18treetreehash_entry4htab (void *);
+extern void gt_ggc_m_P17module_htab_entry4htab (void *);
+extern void gt_ggc_m_P16def_pragma_macro4htab (void *);
+extern void gt_ggc_m_P21pending_abstract_type4htab (void *);
+extern void gt_ggc_m_P10spec_entry4htab (void *);
+extern void gt_ggc_m_P16cxx_int_tree_map4htab (void *);
+extern void gt_ggc_m_P17named_label_entry4htab (void *);
+extern void gt_ggc_m_P12tree_int_map4htab (void *);
+extern void gt_ggc_m_P19lto_symtab_decl_def4htab (void *);
+extern void gt_ggc_m_P25lto_symtab_identifier_def4htab (void *);
+extern void gt_ggc_m_IP9tree_node12splay_tree_s (void *);
+extern void gt_ggc_m_P9tree_nodeP9tree_node12splay_tree_s (void *);
+extern void gt_ggc_m_P12varpool_node4htab (void *);
+extern void gt_ggc_m_P13scev_info_str4htab (void *);
+extern void gt_ggc_m_P23constant_descriptor_rtx4htab (void *);
+extern void gt_ggc_m_P24constant_descriptor_tree4htab (void *);
+extern void gt_ggc_m_P12object_block4htab (void *);
+extern void gt_ggc_m_P7section4htab (void *);
+extern void gt_ggc_m_P17tree_priority_map4htab (void *);
+extern void gt_ggc_m_P8tree_map4htab (void *);
+extern void gt_ggc_m_P9type_hash4htab (void *);
+extern void gt_ggc_m_P13libfunc_entry4htab (void *);
+extern void gt_ggc_m_P23temp_slot_address_entry4htab (void *);
+extern void gt_ggc_m_P15throw_stmt_node4htab (void *);
+extern void gt_ggc_m_P9reg_attrs4htab (void *);
+extern void gt_ggc_m_P9mem_attrs4htab (void *);
+extern void gt_ggc_m_P7rtx_def4htab (void *);
+extern void gt_ggc_m_SP9tree_node12splay_tree_s (void *);
+extern void gt_ggc_m_P16var_loc_list_def4htab (void *);
+extern void gt_ggc_m_P10die_struct4htab (void *);
+extern void gt_ggc_m_P15dwarf_file_data4htab (void *);
+extern void gt_ggc_m_P20indirect_string_node4htab (void *);
+extern void gt_ggc_m_P11cgraph_node4htab (void *);
+extern void gt_ggc_m_II12splay_tree_s (void *);
+extern void gt_ggc_m_P27cgraph_node_set_element_def4htab (void *);
+extern void gt_ggc_m_P11cgraph_edge4htab (void *);
+extern void gt_ggc_m_P9loop_exit4htab (void *);
+extern void gt_ggc_m_P9tree_node4htab (void *);
+
+/* PCH type-walking procedures. */
+#define gt_pch_n_13tree_llvm_map(X) do { \
+ if (X != NULL) gt_pch_nx_tree_llvm_map (X);\
+ } while (0)
+extern void gt_pch_nx_tree_llvm_map (void *);
+#define gt_pch_n_15interface_tuple(X) do { \
+ if (X != NULL) gt_pch_nx_interface_tuple (X);\
+ } while (0)
+extern void gt_pch_nx_interface_tuple (void *);
+#define gt_pch_n_16volatilized_type(X) do { \
+ if (X != NULL) gt_pch_nx_volatilized_type (X);\
+ } while (0)
+extern void gt_pch_nx_volatilized_type (void *);
+#define gt_pch_n_17string_descriptor(X) do { \
+ if (X != NULL) gt_pch_nx_string_descriptor (X);\
+ } while (0)
+extern void gt_pch_nx_string_descriptor (void *);
+#define gt_pch_n_15c_inline_static(X) do { \
+ if (X != NULL) gt_pch_nx_c_inline_static (X);\
+ } while (0)
+extern void gt_pch_nx_c_inline_static (void *);
+#define gt_pch_n_24VEC_c_goto_bindings_p_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_c_goto_bindings_p_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_c_goto_bindings_p_gc (void *);
+#define gt_pch_n_15c_goto_bindings(X) do { \
+ if (X != NULL) gt_pch_nx_c_goto_bindings (X);\
+ } while (0)
+extern void gt_pch_nx_c_goto_bindings (void *);
+#define gt_pch_n_7c_scope(X) do { \
+ if (X != NULL) gt_pch_nx_c_scope (X);\
+ } while (0)
+extern void gt_pch_nx_c_scope (void *);
+#define gt_pch_n_9c_binding(X) do { \
+ if (X != NULL) gt_pch_nx_c_binding (X);\
+ } while (0)
+extern void gt_pch_nx_c_binding (void *);
+#define gt_pch_n_12c_label_vars(X) do { \
+ if (X != NULL) gt_pch_nx_c_label_vars (X);\
+ } while (0)
+extern void gt_pch_nx_c_label_vars (void *);
+#define gt_pch_n_8c_parser(X) do { \
+ if (X != NULL) gt_pch_nx_c_parser (X);\
+ } while (0)
+extern void gt_pch_nx_c_parser (void *);
+#define gt_pch_n_9imp_entry(X) do { \
+ if (X != NULL) gt_pch_nx_imp_entry (X);\
+ } while (0)
+extern void gt_pch_nx_imp_entry (void *);
+#define gt_pch_n_16hashed_attribute(X) do { \
+ if (X != NULL) gt_pch_nx_hashed_attribute (X);\
+ } while (0)
+extern void gt_pch_nx_hashed_attribute (void *);
+#define gt_pch_n_12hashed_entry(X) do { \
+ if (X != NULL) gt_pch_nx_hashed_entry (X);\
+ } while (0)
+extern void gt_pch_nx_hashed_entry (void *);
+#define gt_pch_n_14type_assertion(X) do { \
+ if (X != NULL) gt_pch_nx_type_assertion (X);\
+ } while (0)
+extern void gt_pch_nx_type_assertion (void *);
+#define gt_pch_n_18treetreehash_entry(X) do { \
+ if (X != NULL) gt_pch_nx_treetreehash_entry (X);\
+ } while (0)
+extern void gt_pch_nx_treetreehash_entry (void *);
+#define gt_pch_n_5CPool(X) do { \
+ if (X != NULL) gt_pch_nx_CPool (X);\
+ } while (0)
+extern void gt_pch_nx_CPool (void *);
+#define gt_pch_n_3JCF(X) do { \
+ if (X != NULL) gt_pch_nx_JCF (X);\
+ } while (0)
+extern void gt_pch_nx_JCF (void *);
+#define gt_pch_n_17module_htab_entry(X) do { \
+ if (X != NULL) gt_pch_nx_module_htab_entry (X);\
+ } while (0)
+extern void gt_pch_nx_module_htab_entry (void *);
+#define gt_pch_n_13binding_level(X) do { \
+ if (X != NULL) gt_pch_nx_binding_level (X);\
+ } while (0)
+extern void gt_pch_nx_binding_level (void *);
+#define gt_pch_n_9opt_stack(X) do { \
+ if (X != NULL) gt_pch_nx_opt_stack (X);\
+ } while (0)
+extern void gt_pch_nx_opt_stack (void *);
+#define gt_pch_n_16def_pragma_macro(X) do { \
+ if (X != NULL) gt_pch_nx_def_pragma_macro (X);\
+ } while (0)
+extern void gt_pch_nx_def_pragma_macro (void *);
+#define gt_pch_n_22def_pragma_macro_value(X) do { \
+ if (X != NULL) gt_pch_nx_def_pragma_macro_value (X);\
+ } while (0)
+extern void gt_pch_nx_def_pragma_macro_value (void *);
+#define gt_pch_n_11align_stack(X) do { \
+ if (X != NULL) gt_pch_nx_align_stack (X);\
+ } while (0)
+extern void gt_pch_nx_align_stack (void *);
+#define gt_pch_n_18VEC_tree_gc_vec_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_tree_gc_vec_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_tree_gc_vec_gc (void *);
+#define gt_pch_n_19VEC_const_char_p_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_const_char_p_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_const_char_p_gc (void *);
+#define gt_pch_n_21pending_abstract_type(X) do { \
+ if (X != NULL) gt_pch_nx_pending_abstract_type (X);\
+ } while (0)
+extern void gt_pch_nx_pending_abstract_type (void *);
+#define gt_pch_n_9cp_parser(X) do { \
+ if (X != NULL) gt_pch_nx_cp_parser (X);\
+ } while (0)
+extern void gt_pch_nx_cp_parser (void *);
+#define gt_pch_n_17cp_parser_context(X) do { \
+ if (X != NULL) gt_pch_nx_cp_parser_context (X);\
+ } while (0)
+extern void gt_pch_nx_cp_parser_context (void *);
+#define gt_pch_n_8cp_lexer(X) do { \
+ if (X != NULL) gt_pch_nx_cp_lexer (X);\
+ } while (0)
+extern void gt_pch_nx_cp_lexer (void *);
+#define gt_pch_n_10tree_check(X) do { \
+ if (X != NULL) gt_pch_nx_tree_check (X);\
+ } while (0)
+extern void gt_pch_nx_tree_check (void *);
+#define gt_pch_n_22VEC_deferred_access_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_deferred_access_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_deferred_access_gc (void *);
+#define gt_pch_n_10spec_entry(X) do { \
+ if (X != NULL) gt_pch_nx_spec_entry (X);\
+ } while (0)
+extern void gt_pch_nx_spec_entry (void *);
+#define gt_pch_n_16pending_template(X) do { \
+ if (X != NULL) gt_pch_nx_pending_template (X);\
+ } while (0)
+extern void gt_pch_nx_pending_template (void *);
+#define gt_pch_n_21named_label_use_entry(X) do { \
+ if (X != NULL) gt_pch_nx_named_label_use_entry (X);\
+ } while (0)
+extern void gt_pch_nx_named_label_use_entry (void *);
+#define gt_pch_n_28VEC_deferred_access_check_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_deferred_access_check_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_deferred_access_check_gc (void *);
+#define gt_pch_n_11tinst_level(X) do { \
+ if (X != NULL) gt_pch_nx_tinst_level (X);\
+ } while (0)
+extern void gt_pch_nx_tinst_level (void *);
+#define gt_pch_n_18sorted_fields_type(X) do { \
+ if (X != NULL) gt_pch_nx_sorted_fields_type (X);\
+ } while (0)
+extern void gt_pch_nx_sorted_fields_type (void *);
+#define gt_pch_n_18VEC_tree_pair_s_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_tree_pair_s_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_tree_pair_s_gc (void *);
+#define gt_pch_n_17named_label_entry(X) do { \
+ if (X != NULL) gt_pch_nx_named_label_entry (X);\
+ } while (0)
+extern void gt_pch_nx_named_label_entry (void *);
+#define gt_pch_n_14cp_token_cache(X) do { \
+ if (X != NULL) gt_pch_nx_cp_token_cache (X);\
+ } while (0)
+extern void gt_pch_nx_cp_token_cache (void *);
+#define gt_pch_n_11saved_scope(X) do { \
+ if (X != NULL) gt_pch_nx_saved_scope (X);\
+ } while (0)
+extern void gt_pch_nx_saved_scope (void *);
+#define gt_pch_n_16cxx_int_tree_map(X) do { \
+ if (X != NULL) gt_pch_nx_cxx_int_tree_map (X);\
+ } while (0)
+extern void gt_pch_nx_cxx_int_tree_map (void *);
+#define gt_pch_n_23VEC_cp_class_binding_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_cp_class_binding_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_cp_class_binding_gc (void *);
+#define gt_pch_n_24VEC_cxx_saved_binding_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_cxx_saved_binding_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_cxx_saved_binding_gc (void *);
+#define gt_pch_n_16cp_binding_level(X) do { \
+ if (X != NULL) gt_pch_nx_cp_binding_level (X);\
+ } while (0)
+extern void gt_pch_nx_cp_binding_level (void *);
+#define gt_pch_n_11cxx_binding(X) do { \
+ if (X != NULL) gt_pch_nx_cxx_binding (X);\
+ } while (0)
+extern void gt_pch_nx_cxx_binding (void *);
+#define gt_pch_n_15binding_entry_s(X) do { \
+ if (X != NULL) gt_pch_nx_binding_entry_s (X);\
+ } while (0)
+extern void gt_pch_nx_binding_entry_s (void *);
+#define gt_pch_n_15binding_table_s(X) do { \
+ if (X != NULL) gt_pch_nx_binding_table_s (X);\
+ } while (0)
+extern void gt_pch_nx_binding_table_s (void *);
+#define gt_pch_n_14VEC_tinfo_s_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_tinfo_s_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_tinfo_s_gc (void *);
+#define gt_pch_n_18gnat_binding_level(X) do { \
+ if (X != NULL) gt_pch_nx_gnat_binding_level (X);\
+ } while (0)
+extern void gt_pch_nx_gnat_binding_level (void *);
+#define gt_pch_n_9elab_info(X) do { \
+ if (X != NULL) gt_pch_nx_elab_info (X);\
+ } while (0)
+extern void gt_pch_nx_elab_info (void *);
+#define gt_pch_n_10stmt_group(X) do { \
+ if (X != NULL) gt_pch_nx_stmt_group (X);\
+ } while (0)
+extern void gt_pch_nx_stmt_group (void *);
+#define gt_pch_n_16VEC_parm_attr_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_parm_attr_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_parm_attr_gc (void *);
+#define gt_pch_n_11parm_attr_d(X) do { \
+ if (X != NULL) gt_pch_nx_parm_attr_d (X);\
+ } while (0)
+extern void gt_pch_nx_parm_attr_d (void *);
+#define gt_pch_n_19lto_symtab_decl_def(X) do { \
+ if (X != NULL) gt_pch_nx_lto_symtab_decl_def (X);\
+ } while (0)
+extern void gt_pch_nx_lto_symtab_decl_def (void *);
+#define gt_pch_n_25lto_symtab_identifier_def(X) do { \
+ if (X != NULL) gt_pch_nx_lto_symtab_identifier_def (X);\
+ } while (0)
+extern void gt_pch_nx_lto_symtab_identifier_def (void *);
+#define gt_pch_n_20ssa_operand_memory_d(X) do { \
+ if (X != NULL) gt_pch_nx_ssa_operand_memory_d (X);\
+ } while (0)
+extern void gt_pch_nx_ssa_operand_memory_d (void *);
+#define gt_pch_n_13scev_info_str(X) do { \
+ if (X != NULL) gt_pch_nx_scev_info_str (X);\
+ } while (0)
+extern void gt_pch_nx_scev_info_str (void *);
+#define gt_pch_n_13VEC_gimple_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_gimple_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_gimple_gc (void *);
+#define gt_pch_n_9type_hash(X) do { \
+ if (X != NULL) gt_pch_nx_type_hash (X);\
+ } while (0)
+extern void gt_pch_nx_type_hash (void *);
+#define gt_pch_n_16string_pool_data(X) do { \
+ if (X != NULL) gt_pch_nx_string_pool_data (X);\
+ } while (0)
+extern void gt_pch_nx_string_pool_data (void *);
+#define gt_pch_n_13libfunc_entry(X) do { \
+ if (X != NULL) gt_pch_nx_libfunc_entry (X);\
+ } while (0)
+extern void gt_pch_nx_libfunc_entry (void *);
+#define gt_pch_n_23temp_slot_address_entry(X) do { \
+ if (X != NULL) gt_pch_nx_temp_slot_address_entry (X);\
+ } while (0)
+extern void gt_pch_nx_temp_slot_address_entry (void *);
+#define gt_pch_n_15throw_stmt_node(X) do { \
+ if (X != NULL) gt_pch_nx_throw_stmt_node (X);\
+ } while (0)
+extern void gt_pch_nx_throw_stmt_node (void *);
+#define gt_pch_n_16VEC_eh_region_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_eh_region_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_eh_region_gc (void *);
+#define gt_pch_n_11eh_region_d(X) do { \
+ if (X != NULL) gt_pch_nx_eh_region_d (X);\
+ } while (0)
+extern void gt_pch_nx_eh_region_d (void *);
+#define gt_pch_n_16var_loc_list_def(X) do { \
+ if (X != NULL) gt_pch_nx_var_loc_list_def (X);\
+ } while (0)
+extern void gt_pch_nx_var_loc_list_def (void *);
+#define gt_pch_n_12var_loc_node(X) do { \
+ if (X != NULL) gt_pch_nx_var_loc_node (X);\
+ } while (0)
+extern void gt_pch_nx_var_loc_node (void *);
+#define gt_pch_n_20VEC_die_arg_entry_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_die_arg_entry_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_die_arg_entry_gc (void *);
+#define gt_pch_n_16limbo_die_struct(X) do { \
+ if (X != NULL) gt_pch_nx_limbo_die_struct (X);\
+ } while (0)
+extern void gt_pch_nx_limbo_die_struct (void *);
+#define gt_pch_n_20VEC_pubname_entry_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_pubname_entry_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_pubname_entry_gc (void *);
+#define gt_pch_n_19VEC_dw_attr_node_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_dw_attr_node_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_dw_attr_node_gc (void *);
+#define gt_pch_n_25dw_ranges_by_label_struct(X) do { \
+ if (X != NULL) gt_pch_nx_dw_ranges_by_label_struct (X);\
+ } while (0)
+extern void gt_pch_nx_dw_ranges_by_label_struct (void *);
+#define gt_pch_n_16dw_ranges_struct(X) do { \
+ if (X != NULL) gt_pch_nx_dw_ranges_struct (X);\
+ } while (0)
+extern void gt_pch_nx_dw_ranges_struct (void *);
+#define gt_pch_n_28dw_separate_line_info_struct(X) do { \
+ if (X != NULL) gt_pch_nx_dw_separate_line_info_struct (X);\
+ } while (0)
+extern void gt_pch_nx_dw_separate_line_info_struct (void *);
+#define gt_pch_n_19dw_line_info_struct(X) do { \
+ if (X != NULL) gt_pch_nx_dw_line_info_struct (X);\
+ } while (0)
+extern void gt_pch_nx_dw_line_info_struct (void *);
+#define gt_pch_n_25VEC_deferred_locations_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_deferred_locations_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_deferred_locations_gc (void *);
+#define gt_pch_n_18dw_loc_list_struct(X) do { \
+ if (X != NULL) gt_pch_nx_dw_loc_list_struct (X);\
+ } while (0)
+extern void gt_pch_nx_dw_loc_list_struct (void *);
+#define gt_pch_n_15dwarf_file_data(X) do { \
+ if (X != NULL) gt_pch_nx_dwarf_file_data (X);\
+ } while (0)
+extern void gt_pch_nx_dwarf_file_data (void *);
+#define gt_pch_n_15queued_reg_save(X) do { \
+ if (X != NULL) gt_pch_nx_queued_reg_save (X);\
+ } while (0)
+extern void gt_pch_nx_queued_reg_save (void *);
+#define gt_pch_n_20indirect_string_node(X) do { \
+ if (X != NULL) gt_pch_nx_indirect_string_node (X);\
+ } while (0)
+extern void gt_pch_nx_indirect_string_node (void *);
+#define gt_pch_n_19dw_loc_descr_struct(X) do { \
+ if (X != NULL) gt_pch_nx_dw_loc_descr_struct (X);\
+ } while (0)
+extern void gt_pch_nx_dw_loc_descr_struct (void *);
+#define gt_pch_n_13dw_fde_struct(X) do { \
+ if (X != NULL) gt_pch_nx_dw_fde_struct (X);\
+ } while (0)
+extern void gt_pch_nx_dw_fde_struct (void *);
+#define gt_pch_n_13dw_cfi_struct(X) do { \
+ if (X != NULL) gt_pch_nx_dw_cfi_struct (X);\
+ } while (0)
+extern void gt_pch_nx_dw_cfi_struct (void *);
+#define gt_pch_n_8typeinfo(X) do { \
+ if (X != NULL) gt_pch_nx_typeinfo (X);\
+ } while (0)
+extern void gt_pch_nx_typeinfo (void *);
+#define gt_pch_n_22VEC_alias_set_entry_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_alias_set_entry_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_alias_set_entry_gc (void *);
+#define gt_pch_n_17alias_set_entry_d(X) do { \
+ if (X != NULL) gt_pch_nx_alias_set_entry_d (X);\
+ } while (0)
+extern void gt_pch_nx_alias_set_entry_d (void *);
+#define gt_pch_n_24constant_descriptor_tree(X) do { \
+ if (X != NULL) gt_pch_nx_constant_descriptor_tree (X);\
+ } while (0)
+extern void gt_pch_nx_constant_descriptor_tree (void *);
+#define gt_pch_n_15cgraph_asm_node(X) do { \
+ if (X != NULL) gt_pch_nx_cgraph_asm_node (X);\
+ } while (0)
+extern void gt_pch_nx_cgraph_asm_node (void *);
+#define gt_pch_n_12varpool_node(X) do { \
+ if (X != NULL) gt_pch_nx_varpool_node (X);\
+ } while (0)
+extern void gt_pch_nx_varpool_node (void *);
+#define gt_pch_n_22VEC_cgraph_node_set_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_cgraph_node_set_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_cgraph_node_set_gc (void *);
+#define gt_pch_n_19cgraph_node_set_def(X) do { \
+ if (X != NULL) gt_pch_nx_cgraph_node_set_def (X);\
+ } while (0)
+extern void gt_pch_nx_cgraph_node_set_def (void *);
+#define gt_pch_n_27cgraph_node_set_element_def(X) do { \
+ if (X != NULL) gt_pch_nx_cgraph_node_set_element_def (X);\
+ } while (0)
+extern void gt_pch_nx_cgraph_node_set_element_def (void *);
+#define gt_pch_n_22VEC_cgraph_node_ptr_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_cgraph_node_ptr_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_cgraph_node_ptr_gc (void *);
+#define gt_pch_n_11cgraph_edge(X) do { \
+ if (X != NULL) gt_pch_nx_cgraph_edge (X);\
+ } while (0)
+extern void gt_pch_nx_cgraph_edge (void *);
+#define gt_pch_n_24VEC_ipa_replace_map_p_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_ipa_replace_map_p_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_ipa_replace_map_p_gc (void *);
+#define gt_pch_n_15ipa_replace_map(X) do { \
+ if (X != NULL) gt_pch_nx_ipa_replace_map (X);\
+ } while (0)
+extern void gt_pch_nx_ipa_replace_map (void *);
+#define gt_pch_n_11cgraph_node(X) do { \
+ if (X != NULL) gt_pch_nx_cgraph_node (X);\
+ } while (0)
+extern void gt_pch_nx_cgraph_node (void *);
+#define gt_pch_n_18VEC_basic_block_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_basic_block_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_basic_block_gc (void *);
+#define gt_pch_n_14gimple_bb_info(X) do { \
+ if (X != NULL) gt_pch_nx_gimple_bb_info (X);\
+ } while (0)
+extern void gt_pch_nx_gimple_bb_info (void *);
+#define gt_pch_n_11rtl_bb_info(X) do { \
+ if (X != NULL) gt_pch_nx_rtl_bb_info (X);\
+ } while (0)
+extern void gt_pch_nx_rtl_bb_info (void *);
+#define gt_pch_n_11VEC_edge_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_edge_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_edge_gc (void *);
+#define gt_pch_n_17cselib_val_struct(X) do { \
+ if (X != NULL) gt_pch_nx_cselib_val_struct (X);\
+ } while (0)
+extern void gt_pch_nx_cselib_val_struct (void *);
+#define gt_pch_n_12elt_loc_list(X) do { \
+ if (X != NULL) gt_pch_nx_elt_loc_list (X);\
+ } while (0)
+extern void gt_pch_nx_elt_loc_list (void *);
+#define gt_pch_n_13VEC_loop_p_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_loop_p_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_loop_p_gc (void *);
+#define gt_pch_n_4loop(X) do { \
+ if (X != NULL) gt_pch_nx_loop (X);\
+ } while (0)
+extern void gt_pch_nx_loop (void *);
+#define gt_pch_n_9loop_exit(X) do { \
+ if (X != NULL) gt_pch_nx_loop_exit (X);\
+ } while (0)
+extern void gt_pch_nx_loop_exit (void *);
+#define gt_pch_n_13nb_iter_bound(X) do { \
+ if (X != NULL) gt_pch_nx_nb_iter_bound (X);\
+ } while (0)
+extern void gt_pch_nx_nb_iter_bound (void *);
+#define gt_pch_n_17language_function(X) do { \
+ if (X != NULL) gt_pch_nx_language_function (X);\
+ } while (0)
+extern void gt_pch_nx_language_function (void *);
+#define gt_pch_n_5loops(X) do { \
+ if (X != NULL) gt_pch_nx_loops (X);\
+ } while (0)
+extern void gt_pch_nx_loops (void *);
+#define gt_pch_n_18control_flow_graph(X) do { \
+ if (X != NULL) gt_pch_nx_control_flow_graph (X);\
+ } while (0)
+extern void gt_pch_nx_control_flow_graph (void *);
+#define gt_pch_n_9eh_status(X) do { \
+ if (X != NULL) gt_pch_nx_eh_status (X);\
+ } while (0)
+extern void gt_pch_nx_eh_status (void *);
+#define gt_pch_n_20initial_value_struct(X) do { \
+ if (X != NULL) gt_pch_nx_initial_value_struct (X);\
+ } while (0)
+extern void gt_pch_nx_initial_value_struct (void *);
+#define gt_pch_n_17rtx_constant_pool(X) do { \
+ if (X != NULL) gt_pch_nx_rtx_constant_pool (X);\
+ } while (0)
+extern void gt_pch_nx_rtx_constant_pool (void *);
+#define gt_pch_n_18VEC_temp_slot_p_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_temp_slot_p_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_temp_slot_p_gc (void *);
+#define gt_pch_n_9temp_slot(X) do { \
+ if (X != NULL) gt_pch_nx_temp_slot (X);\
+ } while (0)
+extern void gt_pch_nx_temp_slot (void *);
+#define gt_pch_n_9gimple_df(X) do { \
+ if (X != NULL) gt_pch_nx_gimple_df (X);\
+ } while (0)
+extern void gt_pch_nx_gimple_df (void *);
+#define gt_pch_n_23VEC_call_site_record_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_call_site_record_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_call_site_record_gc (void *);
+#define gt_pch_n_18call_site_record_d(X) do { \
+ if (X != NULL) gt_pch_nx_call_site_record_d (X);\
+ } while (0)
+extern void gt_pch_nx_call_site_record_d (void *);
+#define gt_pch_n_14sequence_stack(X) do { \
+ if (X != NULL) gt_pch_nx_sequence_stack (X);\
+ } while (0)
+extern void gt_pch_nx_sequence_stack (void *);
+#define gt_pch_n_8elt_list(X) do { \
+ if (X != NULL) gt_pch_nx_elt_list (X);\
+ } while (0)
+extern void gt_pch_nx_elt_list (void *);
+#define gt_pch_n_17tree_priority_map(X) do { \
+ if (X != NULL) gt_pch_nx_tree_priority_map (X);\
+ } while (0)
+extern void gt_pch_nx_tree_priority_map (void *);
+#define gt_pch_n_12tree_int_map(X) do { \
+ if (X != NULL) gt_pch_nx_tree_int_map (X);\
+ } while (0)
+extern void gt_pch_nx_tree_int_map (void *);
+#define gt_pch_n_8tree_map(X) do { \
+ if (X != NULL) gt_pch_nx_tree_map (X);\
+ } while (0)
+extern void gt_pch_nx_tree_map (void *);
+#define gt_pch_n_14lang_tree_node(X) do { \
+ if (X != NULL) gt_pch_nx_lang_tree_node (X);\
+ } while (0)
+extern void gt_pch_nx_lang_tree_node (void *);
+#define gt_pch_n_24tree_statement_list_node(X) do { \
+ if (X != NULL) gt_pch_nx_tree_statement_list_node (X);\
+ } while (0)
+extern void gt_pch_nx_tree_statement_list_node (void *);
+#define gt_pch_n_9lang_decl(X) do { \
+ if (X != NULL) gt_pch_nx_lang_decl (X);\
+ } while (0)
+extern void gt_pch_nx_lang_decl (void *);
+#define gt_pch_n_9lang_type(X) do { \
+ if (X != NULL) gt_pch_nx_lang_type (X);\
+ } while (0)
+extern void gt_pch_nx_lang_type (void *);
+#define gt_pch_n_10die_struct(X) do { \
+ if (X != NULL) gt_pch_nx_die_struct (X);\
+ } while (0)
+extern void gt_pch_nx_die_struct (void *);
+#define gt_pch_n_15varray_head_tag(X) do { \
+ if (X != NULL) gt_pch_nx_varray_head_tag (X);\
+ } while (0)
+extern void gt_pch_nx_varray_head_tag (void *);
+#define gt_pch_n_12ptr_info_def(X) do { \
+ if (X != NULL) gt_pch_nx_ptr_info_def (X);\
+ } while (0)
+extern void gt_pch_nx_ptr_info_def (void *);
+#define gt_pch_n_22VEC_constructor_elt_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_constructor_elt_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_constructor_elt_gc (void *);
+#define gt_pch_n_10tree_ann_d(X) do { \
+ if (X != NULL) gt_pch_nx_tree_ann_d (X);\
+ } while (0)
+extern void gt_pch_nx_tree_ann_d (void *);
+#define gt_pch_n_17VEC_alias_pair_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_alias_pair_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_alias_pair_gc (void *);
+#define gt_pch_n_11VEC_tree_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_tree_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_tree_gc (void *);
+#define gt_pch_n_8function(X) do { \
+ if (X != NULL) gt_pch_nx_function (X);\
+ } while (0)
+extern void gt_pch_nx_function (void *);
+#define gt_pch_n_23constant_descriptor_rtx(X) do { \
+ if (X != NULL) gt_pch_nx_constant_descriptor_rtx (X);\
+ } while (0)
+extern void gt_pch_nx_constant_descriptor_rtx (void *);
+#define gt_pch_n_11fixed_value(X) do { \
+ if (X != NULL) gt_pch_nx_fixed_value (X);\
+ } while (0)
+extern void gt_pch_nx_fixed_value (void *);
+#define gt_pch_n_10real_value(X) do { \
+ if (X != NULL) gt_pch_nx_real_value (X);\
+ } while (0)
+extern void gt_pch_nx_real_value (void *);
+#define gt_pch_n_10VEC_rtx_gc(X) do { \
+ if (X != NULL) gt_pch_nx_VEC_rtx_gc (X);\
+ } while (0)
+extern void gt_pch_nx_VEC_rtx_gc (void *);
+#define gt_pch_n_12object_block(X) do { \
+ if (X != NULL) gt_pch_nx_object_block (X);\
+ } while (0)
+extern void gt_pch_nx_object_block (void *);
+#define gt_pch_n_9reg_attrs(X) do { \
+ if (X != NULL) gt_pch_nx_reg_attrs (X);\
+ } while (0)
+extern void gt_pch_nx_reg_attrs (void *);
+#define gt_pch_n_9mem_attrs(X) do { \
+ if (X != NULL) gt_pch_nx_mem_attrs (X);\
+ } while (0)
+extern void gt_pch_nx_mem_attrs (void *);
+#define gt_pch_n_14bitmap_obstack(X) do { \
+ if (X != NULL) gt_pch_nx_bitmap_obstack (X);\
+ } while (0)
+extern void gt_pch_nx_bitmap_obstack (void *);
+#define gt_pch_n_18bitmap_element_def(X) do { \
+ if (X != NULL) gt_pch_nx_bitmap_element_def (X);\
+ } while (0)
+extern void gt_pch_nx_bitmap_element_def (void *);
+#define gt_pch_n_16machine_function(X) do { \
+ if (X != NULL) gt_pch_nx_machine_function (X);\
+ } while (0)
+extern void gt_pch_nx_machine_function (void *);
+#define gt_pch_n_17stack_local_entry(X) do { \
+ if (X != NULL) gt_pch_nx_stack_local_entry (X);\
+ } while (0)
+extern void gt_pch_nx_stack_local_entry (void *);
+#define gt_pch_n_15basic_block_def(X) do { \
+ if (X != NULL) gt_pch_nx_basic_block_def (X);\
+ } while (0)
+extern void gt_pch_nx_basic_block_def (void *);
+#define gt_pch_n_8edge_def(X) do { \
+ if (X != NULL) gt_pch_nx_edge_def (X);\
+ } while (0)
+extern void gt_pch_nx_edge_def (void *);
+#define gt_pch_n_17gimple_seq_node_d(X) do { \
+ if (X != NULL) gt_pch_nx_gimple_seq_node_d (X);\
+ } while (0)
+extern void gt_pch_nx_gimple_seq_node_d (void *);
+#define gt_pch_n_12gimple_seq_d(X) do { \
+ if (X != NULL) gt_pch_nx_gimple_seq_d (X);\
+ } while (0)
+extern void gt_pch_nx_gimple_seq_d (void *);
+#define gt_pch_n_7section(X) do { \
+ if (X != NULL) gt_pch_nx_section (X);\
+ } while (0)
+extern void gt_pch_nx_section (void *);
+#define gt_pch_n_18gimple_statement_d(X) do { \
+ if (X != NULL) gt_pch_nx_gimple_statement_d (X);\
+ } while (0)
+extern void gt_pch_nx_gimple_statement_d (void *);
+#define gt_pch_n_9rtvec_def(X) do { \
+ if (X != NULL) gt_pch_nx_rtvec_def (X);\
+ } while (0)
+extern void gt_pch_nx_rtvec_def (void *);
+#define gt_pch_n_7rtx_def(X) do { \
+ if (X != NULL) gt_pch_nx_rtx_def (X);\
+ } while (0)
+extern void gt_pch_nx_rtx_def (void *);
+#define gt_pch_n_15bitmap_head_def(X) do { \
+ if (X != NULL) gt_pch_nx_bitmap_head_def (X);\
+ } while (0)
+extern void gt_pch_nx_bitmap_head_def (void *);
+#define gt_pch_n_9tree_node(X) do { \
+ if (X != NULL) gt_pch_nx_tree_node (X);\
+ } while (0)
+#define gt_pch_nx_tree_node gt_pch_nx_lang_tree_node
+#define gt_pch_n_6answer(X) do { \
+ if (X != NULL) gt_pch_nx_answer (X);\
+ } while (0)
+extern void gt_pch_nx_answer (void *);
+#define gt_pch_n_9cpp_macro(X) do { \
+ if (X != NULL) gt_pch_nx_cpp_macro (X);\
+ } while (0)
+extern void gt_pch_nx_cpp_macro (void *);
+#define gt_pch_n_9cpp_token(X) do { \
+ if (X != NULL) gt_pch_nx_cpp_token (X);\
+ } while (0)
+extern void gt_pch_nx_cpp_token (void *);
+#define gt_pch_n_9line_maps(X) do { \
+ if (X != NULL) gt_pch_nx_line_maps (X);\
+ } while (0)
+extern void gt_pch_nx_line_maps (void *);
+extern void gt_pch_n_II17splay_tree_node_s (void *);
+extern void gt_pch_n_SP9tree_node17splay_tree_node_s (void *);
+extern void gt_pch_n_P9tree_nodeP9tree_node17splay_tree_node_s (void *);
+extern void gt_pch_n_IP9tree_node17splay_tree_node_s (void *);
+extern void gt_pch_n_P13tree_llvm_map4htab (void *);
+
+void
+gt_pch_n_P13tree_llvm_map4htab (void *x_p)
+{
+#ifdef GCC_PLUGIN_HAVE_PCH
+ struct htab * const x = (struct htab *)x_p;
+ if (gt_pch_note_object (x, x, gt_pch_p_P13tree_llvm_map4htab, gt_e_P13tree_llvm_map4htab))
+ {
+ if ((*x).entries != NULL) {
+ size_t i0;
+ for (i0 = 0; i0 != (size_t)(((*x)).size); i0++) {
+ gt_pch_n_13tree_llvm_map ((*x).entries[i0]);
+ }
+ gt_pch_note_object ((*x).entries, x, gt_pch_p_P13tree_llvm_map4htab, gt_types_enum_last);
+ }
+ }
+/* end ifdef GCC_PLUGIN_HAVE_PCH*/
+#endif
+}
+extern void gt_pch_n_P15interface_tuple4htab (void *);
+extern void gt_pch_n_P16volatilized_type4htab (void *);
+extern void gt_pch_n_P17string_descriptor4htab (void *);
+extern void gt_pch_n_P14type_assertion4htab (void *);
+extern void gt_pch_n_P18treetreehash_entry4htab (void *);
+extern void gt_pch_n_P17module_htab_entry4htab (void *);
+extern void gt_pch_n_P16def_pragma_macro4htab (void *);
+extern void gt_pch_n_P21pending_abstract_type4htab (void *);
+extern void gt_pch_n_P10spec_entry4htab (void *);
+extern void gt_pch_n_P16cxx_int_tree_map4htab (void *);
+extern void gt_pch_n_P17named_label_entry4htab (void *);
+extern void gt_pch_n_P12tree_int_map4htab (void *);
+extern void gt_pch_n_P19lto_symtab_decl_def4htab (void *);
+extern void gt_pch_n_P25lto_symtab_identifier_def4htab (void *);
+extern void gt_pch_n_IP9tree_node12splay_tree_s (void *);
+extern void gt_pch_n_P9tree_nodeP9tree_node12splay_tree_s (void *);
+extern void gt_pch_n_P12varpool_node4htab (void *);
+extern void gt_pch_n_P13scev_info_str4htab (void *);
+extern void gt_pch_n_P23constant_descriptor_rtx4htab (void *);
+extern void gt_pch_n_P24constant_descriptor_tree4htab (void *);
+extern void gt_pch_n_P12object_block4htab (void *);
+extern void gt_pch_n_P7section4htab (void *);
+extern void gt_pch_n_P17tree_priority_map4htab (void *);
+extern void gt_pch_n_P8tree_map4htab (void *);
+extern void gt_pch_n_P9type_hash4htab (void *);
+extern void gt_pch_n_P13libfunc_entry4htab (void *);
+extern void gt_pch_n_P23temp_slot_address_entry4htab (void *);
+extern void gt_pch_n_P15throw_stmt_node4htab (void *);
+extern void gt_pch_n_P9reg_attrs4htab (void *);
+extern void gt_pch_n_P9mem_attrs4htab (void *);
+extern void gt_pch_n_P7rtx_def4htab (void *);
+extern void gt_pch_n_SP9tree_node12splay_tree_s (void *);
+extern void gt_pch_n_P16var_loc_list_def4htab (void *);
+extern void gt_pch_n_P10die_struct4htab (void *);
+extern void gt_pch_n_P15dwarf_file_data4htab (void *);
+extern void gt_pch_n_P20indirect_string_node4htab (void *);
+extern void gt_pch_n_P11cgraph_node4htab (void *);
+extern void gt_pch_n_II12splay_tree_s (void *);
+extern void gt_pch_n_P27cgraph_node_set_element_def4htab (void *);
+extern void gt_pch_n_P11cgraph_edge4htab (void *);
+extern void gt_pch_n_P9loop_exit4htab (void *);
+extern void gt_pch_n_P9tree_node4htab (void *);
+
+/* Local pointer-walking routines. */
+extern void gt_pch_p_13tree_llvm_map
+ (void *, void *, gt_pointer_operator, void *);
+
+void
+gt_pch_p_13tree_llvm_map (ATTRIBUTE_UNUSED void *this_obj,
+ void *x_p,
+ ATTRIBUTE_UNUSED gt_pointer_operator op,
+ ATTRIBUTE_UNUSED void *cookie)
+{
+#ifdef GCC_PLUGIN_HAVE_PCH
+ struct tree_llvm_map * const x ATTRIBUTE_UNUSED = (struct tree_llvm_map *)x_p;
+ if ((void *)(x) == this_obj)
+ op (&((*x).base.from), cookie);
+/* end ifdef GCC_PLUGIN_HAVE_PCH */
+#endif
+}
+extern void gt_pch_p_15interface_tuple
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_16volatilized_type
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_17string_descriptor
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_15c_inline_static
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_24VEC_c_goto_bindings_p_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_15c_goto_bindings
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_7c_scope
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9c_binding
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_12c_label_vars
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_8c_parser
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9imp_entry
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_16hashed_attribute
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_12hashed_entry
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_14type_assertion
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_18treetreehash_entry
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_5CPool
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_3JCF
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_17module_htab_entry
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_13binding_level
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9opt_stack
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_16def_pragma_macro
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_22def_pragma_macro_value
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_11align_stack
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_18VEC_tree_gc_vec_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_19VEC_const_char_p_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_21pending_abstract_type
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9cp_parser
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_17cp_parser_context
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_8cp_lexer
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_10tree_check
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_22VEC_deferred_access_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_10spec_entry
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_16pending_template
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_21named_label_use_entry
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_28VEC_deferred_access_check_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_11tinst_level
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_18sorted_fields_type
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_18VEC_tree_pair_s_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_17named_label_entry
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_14cp_token_cache
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_11saved_scope
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_16cxx_int_tree_map
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_23VEC_cp_class_binding_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_24VEC_cxx_saved_binding_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_16cp_binding_level
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_11cxx_binding
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_15binding_entry_s
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_15binding_table_s
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_14VEC_tinfo_s_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_18gnat_binding_level
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9elab_info
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_10stmt_group
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_16VEC_parm_attr_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_11parm_attr_d
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_19lto_symtab_decl_def
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_25lto_symtab_identifier_def
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_20ssa_operand_memory_d
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_13scev_info_str
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_13VEC_gimple_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9type_hash
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_16string_pool_data
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_13libfunc_entry
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_23temp_slot_address_entry
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_15throw_stmt_node
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_16VEC_eh_region_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_11eh_region_d
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_16var_loc_list_def
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_12var_loc_node
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_20VEC_die_arg_entry_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_16limbo_die_struct
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_20VEC_pubname_entry_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_19VEC_dw_attr_node_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_25dw_ranges_by_label_struct
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_16dw_ranges_struct
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_28dw_separate_line_info_struct
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_19dw_line_info_struct
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_25VEC_deferred_locations_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_18dw_loc_list_struct
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_15dwarf_file_data
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_15queued_reg_save
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_20indirect_string_node
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_19dw_loc_descr_struct
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_13dw_fde_struct
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_13dw_cfi_struct
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_8typeinfo
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_22VEC_alias_set_entry_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_17alias_set_entry_d
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_24constant_descriptor_tree
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_15cgraph_asm_node
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_12varpool_node
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_22VEC_cgraph_node_set_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_19cgraph_node_set_def
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_27cgraph_node_set_element_def
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_22VEC_cgraph_node_ptr_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_11cgraph_edge
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_24VEC_ipa_replace_map_p_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_15ipa_replace_map
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_11cgraph_node
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_18VEC_basic_block_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_14gimple_bb_info
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_11rtl_bb_info
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_11VEC_edge_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_17cselib_val_struct
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_12elt_loc_list
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_13VEC_loop_p_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_4loop
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9loop_exit
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_13nb_iter_bound
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_17language_function
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_5loops
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_18control_flow_graph
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9eh_status
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_20initial_value_struct
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_17rtx_constant_pool
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_18VEC_temp_slot_p_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9temp_slot
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9gimple_df
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_23VEC_call_site_record_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_18call_site_record_d
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_14sequence_stack
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_8elt_list
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_17tree_priority_map
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_12tree_int_map
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_8tree_map
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_14lang_tree_node
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_24tree_statement_list_node
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9lang_decl
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9lang_type
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_10die_struct
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_15varray_head_tag
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_12ptr_info_def
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_22VEC_constructor_elt_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_10tree_ann_d
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_17VEC_alias_pair_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_11VEC_tree_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_8function
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_23constant_descriptor_rtx
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_11fixed_value
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_10real_value
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_10VEC_rtx_gc
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_12object_block
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9reg_attrs
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9mem_attrs
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_14bitmap_obstack
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_18bitmap_element_def
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_16machine_function
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_17stack_local_entry
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_15basic_block_def
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_8edge_def
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_17gimple_seq_node_d
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_12gimple_seq_d
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_7section
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_18gimple_statement_d
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9rtvec_def
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_7rtx_def
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_15bitmap_head_def
+ (void *, void *, gt_pointer_operator, void *);
+#define gt_pch_p_9tree_node gt_pch_p_14lang_tree_node
+extern void gt_pch_p_6answer
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9cpp_macro
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9cpp_token
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_9line_maps
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_II17splay_tree_node_s
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_SP9tree_node17splay_tree_node_s
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P9tree_nodeP9tree_node17splay_tree_node_s
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_IP9tree_node17splay_tree_node_s
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P13tree_llvm_map4htab
+ (void *, void *, gt_pointer_operator, void *);
+
+void
+gt_pch_p_P13tree_llvm_map4htab (ATTRIBUTE_UNUSED void *this_obj,
+ void *x_p,
+ ATTRIBUTE_UNUSED gt_pointer_operator op,
+ ATTRIBUTE_UNUSED void *cookie)
+{
+#ifdef GCC_PLUGIN_HAVE_PCH
+ struct htab * const x ATTRIBUTE_UNUSED = (struct htab *)x_p;
+ if ((*x).entries != NULL) {
+ size_t i0;
+ for (i0 = 0; i0 != (size_t)(((*x)).size); i0++) {
+ if ((void *)((*x).entries) == this_obj)
+ op (&((*x).entries[i0]), cookie);
+ }
+ if ((void *)(x) == this_obj)
+ op (&((*x).entries), cookie);
+ }
+/* end ifdef GCC_PLUGIN_HAVE_PCH */
+#endif
+}
+extern void gt_pch_p_P15interface_tuple4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P16volatilized_type4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P17string_descriptor4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P14type_assertion4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P18treetreehash_entry4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P17module_htab_entry4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P16def_pragma_macro4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P21pending_abstract_type4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P10spec_entry4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P16cxx_int_tree_map4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P17named_label_entry4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P12tree_int_map4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P19lto_symtab_decl_def4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P25lto_symtab_identifier_def4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_IP9tree_node12splay_tree_s
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P9tree_nodeP9tree_node12splay_tree_s
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P12varpool_node4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P13scev_info_str4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P23constant_descriptor_rtx4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P24constant_descriptor_tree4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P12object_block4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P7section4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P17tree_priority_map4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P8tree_map4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P9type_hash4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P13libfunc_entry4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P23temp_slot_address_entry4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P15throw_stmt_node4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P9reg_attrs4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P9mem_attrs4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P7rtx_def4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_SP9tree_node12splay_tree_s
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P16var_loc_list_def4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P10die_struct4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P15dwarf_file_data4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P20indirect_string_node4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P11cgraph_node4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_II12splay_tree_s
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P27cgraph_node_set_element_def4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P11cgraph_edge4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P9loop_exit4htab
+ (void *, void *, gt_pointer_operator, void *);
+extern void gt_pch_p_P9tree_node4htab
+ (void *, void *, gt_pointer_operator, void *);
+
+/* GC roots. */
+
+EXPORTED_CONST struct ggc_cache_tab gt_ggc_rc__gt_llvm_cache_h[] = {
+ {
+ &llvm_cache,
+ 1,
+ sizeof (llvm_cache),
+ >_ggc_mx_tree_llvm_map,
+ >_pch_nx_tree_llvm_map,
+ &tree_llvm_map_marked_p
+ },
+ LAST_GGC_CACHE_TAB
+};
+
+EXPORTED_CONST struct ggc_root_tab gt_pch_rc__gt_llvm_cache_h[] = {
+ {
+ &llvm_cache,
+ 1,
+ sizeof (llvm_cache),
+ >_ggc_m_P13tree_llvm_map4htab,
+ >_pch_n_P13tree_llvm_map4htab
+ },
+ LAST_GGC_ROOT_TAB
+};
+
+
+void
+gt_ggc_mx_tree_llvm_map (void *x_p)
+{
+ struct tree_llvm_map * const x = (struct tree_llvm_map *)x_p;
+ if (ggc_test_and_set_mark (x))
+ {
+ gt_ggc_m_9tree_node ((*x).base.from);
+ }
+}
+
+void
+gt_pch_nx_tree_llvm_map (void *x_p)
+{
+#ifdef GCC_PLUGIN_HAVE_PCH
+ struct tree_llvm_map * const x = (struct tree_llvm_map *)x_p;
+ if (gt_pch_note_object (x, x, gt_pch_p_13tree_llvm_map, gt_ggc_e_13tree_llvm_map))
+ {
+ gt_pch_n_9tree_node ((*x).base.from);
+ }
+/* end ifdef GCC_PLUGIN_HAVE_PCH*/
+#endif
+}
From baldrick at free.fr Mon Sep 14 09:03:12 2009
From: baldrick at free.fr (Duncan Sands)
Date: Mon, 14 Sep 2009 14:03:12 -0000
Subject: [llvm-commits] [gcc-plugin] r81763 -
/gcc-plugin/trunk/gcc-patches/gengtype.diff
Message-ID: <200909141403.n8EE3C6L007411@zion.cs.uiuc.edu>
Author: baldrick
Date: Mon Sep 14 09:03:12 2009
New Revision: 81763
URL: http://llvm.org/viewvc/llvm-project?rev=81763&view=rev
Log:
This patch is no longer needed.
Removed:
gcc-plugin/trunk/gcc-patches/gengtype.diff
Removed: gcc-plugin/trunk/gcc-patches/gengtype.diff
URL: http://llvm.org/viewvc/llvm-project/gcc-plugin/trunk/gcc-patches/gengtype.diff?rev=81762&view=auto
==============================================================================
--- gcc-plugin/trunk/gcc-patches/gengtype.diff (original)
+++ gcc-plugin/trunk/gcc-patches/gengtype.diff (removed)
@@ -1,737 +0,0 @@
-Index: lto/gcc/doc/plugins.texi
-===================================================================
---- lto.orig/gcc/doc/plugins.texi 2009-09-01 00:16:27.962891836 +0200
-+++ lto/gcc/doc/plugins.texi 2009-09-01 10:21:15.728775623 +0200
-@@ -226,12 +226,16 @@
- their own @code{GTY}-ed data. This can be done with the
- @code{PLUGIN_REGISTER_GGC_ROOTS} pseudo-event with a null callback and
- the extra root table as @code{user_data}. Running the @code{gengtype
---p @var{source-dir} @var{file-list} @var{plugin*.c} ...} utility
--generates this extra root table.
-+-P @file{gt-plugin.h} @var{source-dir} @var{file-list} @var{plugin*.c}
-+...} utility generates this extra root table, with the PCH related
-+generated code kept wrapped with the @code{#ifdef
-+GCC_PLUGIN_HAVE_PCH}, so disabled by default.
-
- You should understand the details of memory management inside GCC
- before using @code{PLUGIN_GGC_MARKING} or
-- at code{PLUGIN_REGISTER_GGC_ROOTS}.
-+ at code{PLUGIN_REGISTER_GGC_ROOTS}. Notice that using plugins which
-+need these features may break the generation of precompiled headers
-+[PCH], unless these plugins take specific measures.
-
-
- @section Giving information about a plugin
-Index: lto/gcc/gengtype.c
-===================================================================
---- lto.orig/gcc/gengtype.c 2009-09-01 10:20:35.755693766 +0200
-+++ lto/gcc/gengtype.c 2009-09-01 10:21:15.732708428 +0200
-@@ -24,6 +24,7 @@
- #include "errors.h" /* for fatal */
- #include "double-int.h"
-
-+
- /* Data types, macros, etc. used only in this file. */
-
- /* Kinds of types we can understand. */
-@@ -64,6 +65,7 @@
- type_p type;
- struct fileloc line;
- options_p opt;
-+ bool inplugin; /* flag set if appearing inside a plugin */
- };
-
- #define NUM_PARAM 10
-@@ -83,6 +85,7 @@
- type_p next;
- type_p pointer_to;
- enum gc_used_enum gc_used;
-+ bool inplugin;
- union {
- type_p p;
- struct {
-@@ -145,6 +148,12 @@
- directory. */
- static char** plugin_files;
- static int nb_plugin_files;
-+/* index of first plugin file in gt_files */
-+static int first_plugin_file_ix= -1;
-+/* the generated plugin output name & file */
-+static char* plugin_output_filename;
-+static outf_p plugin_output;
-+
-
- /* The output header file that is included into pretty much every
- source file. */
-@@ -167,12 +176,16 @@
-
-
- /* Nonzero iff an error has occurred. */
--bool hit_error = false;
-+bool hit_error = FALSE;
-+/* Flag set when parsing a plugin file */
-+bool is_plugin_file = FALSE;
-+
-
- static void gen_rtx_next (void);
- static void write_rtx_next (void);
- static void open_base_files (void);
- static void close_output_files (void);
-+static void output_delayed_functions (void);
-
- /* Report an error at POS, printing MSG. */
-
-@@ -465,8 +478,19 @@
- if (plugin_files)
- {
- int i;
-+ first_plugin_file_ix = nfiles;
- for (i = 0; i < nb_plugin_files; i++)
-- gt_files[nfiles++] = plugin_files[i];
-+ {
-+ /* Each added entry in gt_files should have additional
-+ space for its lang_bitmap before. */
-+ int plugfilen = strlen (plugin_files[i]);
-+ char* plugent =
-+ (char*) xcalloc (1, plugfilen+1 + sizeof (lang_bitmap));
-+ plugent += sizeof (lang_bitmap);
-+ strcpy(plugent, plugin_files[i]);
-+ gt_files[nfiles++] = plugent;
-+ /* We don't bother freeing plugent ! */
-+ }
- }
- num_gt_files = nfiles;
- }
-@@ -512,17 +536,18 @@
- /* The one and only TYPE_STRING. */
-
- static struct type string_type = {
-- TYPE_STRING, 0, 0, GC_USED, {0}
-+ TYPE_STRING, 0, 0, GC_USED, false, {0}
- };
-
- /* The two and only TYPE_SCALARs. Their u.scalar_is_char flags are
- set to appropriate values at the beginning of main. */
-
- static struct type scalar_nonchar = {
-- TYPE_SCALAR, 0, 0, GC_USED, {0}
-+ TYPE_SCALAR, 0, 0, GC_USED, false, {0}
- };
-+
- static struct type scalar_char = {
-- TYPE_SCALAR, 0, 0, GC_USED, {0}
-+ TYPE_SCALAR, 0, 0, GC_USED, false, {0}
- };
-
- /* Lists of various things. */
-@@ -663,8 +688,9 @@
- isunion ? "union" : "struct", s->u.s.tag);
- error_at_line (&s->u.s.line, "previous definition here");
- }
--
-+
- s->kind = isunion ? TYPE_UNION : TYPE_STRUCT;
-+ s->inplugin = is_plugin_file;
- s->u.s.tag = name;
- s->u.s.line = *pos;
- s->u.s.fields = fields;
-@@ -709,6 +735,7 @@
- s->next = structures;
- structures = s;
- s->kind = isunion ? TYPE_UNION : TYPE_STRUCT;
-+ s->inplugin = is_plugin_file;
- s->u.s.tag = name;
- structures = s;
- return s;
-@@ -732,6 +759,7 @@
- {
- res = XCNEW (struct type);
- res->kind = TYPE_PARAM_STRUCT;
-+ res->inplugin = is_plugin_file;
- res->next = param_structs;
- param_structs = res;
- res->u.param_struct.stru = t;
-@@ -760,6 +788,7 @@
- {
- type_p r = XCNEW (struct type);
- r->kind = TYPE_POINTER;
-+ r->inplugin = is_plugin_file;
- r->u.p = t;
- t->pointer_to = r;
- }
-@@ -775,6 +804,7 @@
-
- v = XCNEW (struct type);
- v->kind = TYPE_ARRAY;
-+ v->inplugin = is_plugin_file;
- v->u.a.p = t;
- v->u.a.len = len;
- return v;
-@@ -819,6 +849,7 @@
- n->line = *pos;
- n->opt = o;
- n->next = variables;
-+ n->inplugin = is_plugin_file;
- variables = n;
- }
-
-@@ -1492,6 +1523,9 @@
- f = XCNEW (struct outf);
- f->next = output_files;
- f->name = oname;
-+ i = f->buflength = 4096;
-+ f->buf = XNEWVEC (char, i);
-+ f->bufused = 0;
- output_files = f;
-
- oprintf (f, "/* Type information for %s.\n", name);
-@@ -1508,7 +1542,7 @@
- void
- oprintf (outf_p o, const char *format, ...)
- {
-- char *s;
-+ char *s = NULL;
- size_t slength;
- va_list ap;
-
-@@ -1516,7 +1550,11 @@
- in that case. */
- if (!o)
- return;
--
-+
-+ gcc_assert (o->buf != NULL);
-+
-+ gcc_assert (o->bufused <= o->buflength);
-+
- va_start (ap, format);
- slength = vasprintf (&s, format, ap);
- if (s == NULL || (int)slength < 0)
-@@ -1526,16 +1564,24 @@
- if (o->bufused + slength > o->buflength)
- {
- size_t new_len = o->buflength;
-+ char *oldbuf = o->buf;
- if (new_len == 0)
- new_len = 1024;
- do {
- new_len *= 2;
- } while (o->bufused + slength >= new_len);
-- o->buf = XRESIZEVEC (char, o->buf, new_len);
-+ o->buf = XNEWVEC (char, new_len);
-+ if (oldbuf)
-+ {
-+ memcpy(o->buf, oldbuf, o->bufused);
-+ oldbuf[0] = 0;
-+ }
-+ free (oldbuf);
- o->buflength = new_len;
- }
- memcpy (o->buf + o->bufused, s, slength);
- o->bufused += slength;
-+ gcc_assert (o->bufused <= o->buflength);
- free (s);
- }
-
-@@ -1546,10 +1592,13 @@
- {
- size_t i;
-
-- if (nb_plugin_files > 0 && plugin_files)
-+ if (nb_plugin_files > 0 && plugin_files)
- return;
--
-+
-+ /* header file should be generated even in plugin mode */
- header_file = create_file ("GCC", "gtype-desc.h");
-+
-+
-
- base_files = XNEWVEC (outf_p, num_lang_dirs);
-
-@@ -1567,7 +1616,8 @@
- "hard-reg-set.h", "basic-block.h", "cselib.h", "insn-addr.h",
- "optabs.h", "libfuncs.h", "debug.h", "ggc.h", "cgraph.h",
- "tree-flow.h", "reload.h", "cpp-id-data.h", "tree-chrec.h",
-- "cfglayout.h", "except.h", "output.h", "gimple.h", "cfgloop.h", NULL
-+ "cfglayout.h", "except.h", "output.h", "gimple.h", "cfgloop.h",
-+ NULL
- };
- const char *const *ifp;
- outf_p gtype_desc_c;
-@@ -1712,15 +1762,19 @@
- input_file = "system.h";
-
- /* In plugin mode, return NULL unless the input_file is one of the
-- plugin_files. */
-+ plugin_files or is the specified plugin_output_filename. */
- if (plugin_files && nb_plugin_files > 0)
- {
- int ix= -1, i;
- for (i = 0; i < nb_plugin_files && ix < 0; i++)
-- if (strcmp (input_file, plugin_files[i]) == 0)
-- ix = i;
-- if (ix < 0)
-+ if (strcmp (input_file, plugin_files[i]) == 0)
-+ ix = i;
-+ if (ix < 0
-+ && plugin_output_filename
-+ && strcmp (input_file, plugin_output_filename))
- return NULL;
-+ if (plugin_output_filename)
-+ return plugin_output;
- }
-
- /* Determine the output file name. */
-@@ -1763,9 +1817,9 @@
-
- if (lang_index >= 0)
- return base_files[lang_index];
--
-+
- output_name = "gtype-desc.c";
-- for_name = NULL;
-+ for_name = "GCC";
- }
-
- /* Look through to see if we've ever seen this output filename before. */
-@@ -1832,6 +1886,9 @@
- fatal ("writing output file %s: %s", of->name, strerror (errno));
- if (fclose (newfile) != 0)
- fatal ("closing output file %s: %s", of->name, strerror (errno));
-+ free(of->buf);
-+ of->buf = NULL;
-+ of->bufused = of->buflength = 0;
- }
- }
-
-@@ -1864,6 +1921,7 @@
- const char *reorder_note_routine;
- const char *comment;
- int skip_hooks; /* skip hook generation if non zero */
-+ int is_pch; /* set for PCH stuff to output ifndef */
- };
-
- static void output_escaped_param (struct walk_type_data *d,
-@@ -1873,6 +1931,7 @@
- static void write_func_for_structure
- (type_p orig_s, type_p s, type_p * param,
- const struct write_types_data *wtd);
-+static void delay_func_for_structure (type_p s, const struct write_types_data* wtd);
- static void write_types_process_field
- (type_p f, const struct walk_type_data *d);
- static void write_types (type_p structures,
-@@ -2587,6 +2646,8 @@
- }
- oprintf (d.of, " (void *x_p)\n");
- oprintf (d.of, "{\n");
-+ if (plugin_output && d.of == plugin_output && wtd->is_pch)
-+ oprintf (d.of, "#ifdef GCC_PLUGIN_HAVE_PCH\n");
- oprintf (d.of, " %s %s * %sx = (%s %s *)x_p;\n",
- s->kind == TYPE_UNION ? "union" : "struct", s->u.s.tag,
- chain_next == NULL ? "const " : "",
-@@ -2691,6 +2752,8 @@
- oprintf (d.of, " }\n");
- if (chain_circular != NULL)
- oprintf (d.of, " while (x != xlimit);\n");
-+ if (plugin_output && d.of == plugin_output && wtd->is_pch)
-+ oprintf (d.of, "/* end ifdef GCC_PLUGIN_HAVE_PCH*/\n#endif\n");
- oprintf (d.of, "}\n");
- }
-
-@@ -2701,8 +2764,9 @@
- const struct write_types_data *wtd)
- {
- type_p s;
--
-- oprintf (header_file, "\n/* %s*/\n", wtd->comment);
-+ outf_p outheadf = plugin_output_filename ? plugin_output : header_file;
-+
-+ oprintf (outheadf, "\n/* %s*/\n", wtd->comment);
- for (s = structures; s; s = s->next)
- if (s->gc_used == GC_POINTED_TO
- || s->gc_used == GC_MAYBE_POINTED_TO)
-@@ -2713,13 +2777,13 @@
- && s->u.s.line.file == NULL)
- continue;
-
-- oprintf (header_file, "#define gt_%s_", wtd->prefix);
-- output_mangled_typename (header_file, s);
-- oprintf (header_file, "(X) do { \\\n");
-- oprintf (header_file,
-+ oprintf (outheadf, "#define gt_%s_", wtd->prefix);
-+ output_mangled_typename (outheadf, s);
-+ oprintf (outheadf, "(X) do { \\\n");
-+ oprintf (outheadf,
- " if (X != NULL) gt_%sx_%s (X);\\\n", wtd->prefix,
- s->u.s.tag);
-- oprintf (header_file,
-+ oprintf (outheadf,
- " } while (0)\n");
-
- for (opt = s->u.s.opt; opt; opt = opt->next)
-@@ -2729,7 +2793,7 @@
- if (t->kind == TYPE_STRUCT
- || t->kind == TYPE_UNION
- || t->kind == TYPE_LANG_STRUCT)
-- oprintf (header_file,
-+ oprintf (outheadf,
- "#define gt_%sx_%s gt_%sx_%s\n",
- wtd->prefix, s->u.s.tag, wtd->prefix, t->u.s.tag);
- else
-@@ -2741,7 +2805,7 @@
- continue;
-
- /* Declare the marker procedure only once. */
-- oprintf (header_file,
-+ oprintf (outheadf,
- "extern void gt_%sx_%s (void *);\n",
- wtd->prefix, s->u.s.tag);
-
-@@ -2752,7 +2816,10 @@
- continue;
- }
-
-- if (s->kind == TYPE_LANG_STRUCT)
-+ /* in plugin mode, the write_func_for_structure should be delayed */
-+ if (nb_plugin_files > 0 && plugin_output_filename)
-+ delay_func_for_structure (s, wtd);
-+ else if (s->kind == TYPE_LANG_STRUCT)
- {
- type_p ss;
- for (ss = s->u.s.lang_struct; ss; ss = ss->next)
-@@ -2769,9 +2836,9 @@
- type_p stru = s->u.param_struct.stru;
-
- /* Declare the marker procedure. */
-- oprintf (header_file, "extern void gt_%s_", wtd->prefix);
-- output_mangled_typename (header_file, s);
-- oprintf (header_file, " (void *);\n");
-+ oprintf (outheadf, "extern void gt_%s_", wtd->prefix);
-+ output_mangled_typename (outheadf, s);
-+ oprintf (outheadf, " (void *);\n");
-
- if (stru->u.s.line.file == NULL)
- {
-@@ -2795,6 +2862,7 @@
- {
- "ggc_m", NULL, "ggc_mark", "ggc_test_and_set_mark", NULL,
- "GC marker procedures. ",
-+ FALSE,
- FALSE
- };
-
-@@ -2803,6 +2871,7 @@
- "pch_n", "pch_p", "gt_pch_note_object", "gt_pch_note_object",
- "gt_pch_note_reorder",
- "PCH type-walking procedures. ",
-+ TRUE,
- TRUE
- };
-
-@@ -2875,11 +2944,15 @@
- "\tATTRIBUTE_UNUSED gt_pointer_operator op,\n"
- "\tATTRIBUTE_UNUSED void *cookie)\n");
- oprintf (d.of, "{\n");
-+ if (plugin_output && d.of == plugin_output)
-+ oprintf (d.of, "#ifdef GCC_PLUGIN_HAVE_PCH\n");
- oprintf (d.of, " %s %s * const x ATTRIBUTE_UNUSED = (%s %s *)x_p;\n",
- s->kind == TYPE_UNION ? "union" : "struct", s->u.s.tag,
- s->kind == TYPE_UNION ? "union" : "struct", s->u.s.tag);
- d.indent = 2;
- walk_type (s, &d);
-+ if (plugin_output && d.of == plugin_output)
-+ oprintf (d.of, "/* end ifdef GCC_PLUGIN_HAVE_PCH */\n#endif\n");
- oprintf (d.of, "}\n");
- }
-
-@@ -2888,11 +2961,13 @@
- static void
- write_local (type_p structures, type_p param_structs)
- {
-+ outf_p outheadf = plugin_output_filename ? plugin_output : header_file;
-+
- type_p s;
-
-- if (!header_file)
-+ if (!outheadf)
- return;
-- oprintf (header_file, "\n/* Local pointer-walking routines. */\n");
-+ oprintf (outheadf, "\n/* Local pointer-walking routines. */\n");
- for (s = structures; s; s = s->next)
- if (s->gc_used == GC_POINTED_TO
- || s->gc_used == GC_MAYBE_POINTED_TO)
-@@ -2910,11 +2985,11 @@
- || t->kind == TYPE_UNION
- || t->kind == TYPE_LANG_STRUCT)
- {
-- oprintf (header_file, "#define gt_pch_p_");
-- output_mangled_typename (header_file, s);
-- oprintf (header_file, " gt_pch_p_");
-- output_mangled_typename (header_file, t);
-- oprintf (header_file, "\n");
-+ oprintf (outheadf, "#define gt_pch_p_");
-+ output_mangled_typename (outheadf, s);
-+ oprintf (outheadf, " gt_pch_p_");
-+ output_mangled_typename (outheadf, t);
-+ oprintf (outheadf, "\n");
- }
- else
- error_at_line (&s->u.s.line,
-@@ -2925,9 +3000,9 @@
- continue;
-
- /* Declare the marker procedure only once. */
-- oprintf (header_file, "extern void gt_pch_p_");
-- output_mangled_typename (header_file, s);
-- oprintf (header_file,
-+ oprintf (outheadf, "extern void gt_pch_p_");
-+ output_mangled_typename (outheadf, s);
-+ oprintf (outheadf,
- "\n (void *, void *, gt_pointer_operator, void *);\n");
-
- if (s->kind == TYPE_LANG_STRUCT)
-@@ -2947,9 +3022,9 @@
- type_p stru = s->u.param_struct.stru;
-
- /* Declare the marker procedure. */
-- oprintf (header_file, "extern void gt_pch_p_");
-- output_mangled_typename (header_file, s);
-- oprintf (header_file,
-+ oprintf (outheadf, "extern void gt_pch_p_");
-+ output_mangled_typename (outheadf, s);
-+ oprintf (outheadf,
- "\n (void *, void *, gt_pointer_operator, void *);\n");
-
- if (stru->u.s.line.file == NULL)
-@@ -2970,17 +3045,60 @@
- }
- }
-
--/* Write out the 'enum' definition for gt_types_enum. */
-+/* Write out only to header_file the 'enum' definition for gt_types_enum. */
-
- static void
- write_enum_defn (type_p structures, type_p param_structs)
- {
-- type_p s;
--
-+ type_p s = NULL;
-+ /* in plugin mode, define dynamically the enumeration values */
-+ if (plugin_output)
-+ {
-+ int cnt = 0;
-+ oprintf (plugin_output, "\n/* Dynamic enumeration of plugin types. */\n");
-+ oprintf (plugin_output, "#ifdef GCC_PLUGIN_HAVE_PCH\n");
-+ oprintf (plugin_output, "static int gccplugin_type_base;\n");
-+
-+ for (s = structures; s; s = s->next)
-+ {
-+ if (!s->inplugin)
-+ continue;
-+ if (s->gc_used == GC_POINTED_TO
-+ || s->gc_used == GC_MAYBE_POINTED_TO)
-+ {
-+ if (s->gc_used == GC_MAYBE_POINTED_TO
-+ && s->u.s.line.file == NULL)
-+ continue;
-+ oprintf (plugin_output, "#define gt_ggc_e_");
-+ output_mangled_typename (plugin_output, s);
-+ oprintf (plugin_output,
-+ " ((gccplugin_type_base>0)?(gccplugin_type_base+%d):0)\n",
-+ cnt);
-+ cnt++;
-+ }
-+ }
-+ for (s = param_structs; s; s = s->next)
-+ if (s->gc_used == GC_POINTED_TO && s->inplugin)
-+ {
-+ oprintf (plugin_output, "#define gt_e_");
-+ output_mangled_typename (plugin_output, s);
-+ oprintf (plugin_output,
-+ " ((gccplugin_type_base>0)?(gccplugin_type_base+%d):0)\n",
-+ cnt);
-+ cnt++;
-+ }
-+ oprintf (plugin_output,
-+ "\n#define GCCPLUGIN_TYPE_COUNT %d\n", cnt);
-+ oprintf (plugin_output, "/* end ifdef GCC_PLUGIN_HAVE_PCH */\n#endif\n");
-+ return;
-+ }
-+
-+ /* write only to header_file */
- if (!header_file)
- return;
-- oprintf (header_file, "\n/* Enumeration of types known. */\n");
-+ oprintf (header_file, "\n/* Enumeration of known types. */\n");
- oprintf (header_file, "enum gt_types_enum {\n");
-+ oprintf (header_file, " gt_types_enum_firstempty,\n");
- for (s = structures; s; s = s->next)
- if (s->gc_used == GC_POINTED_TO
- || s->gc_used == GC_MAYBE_POINTED_TO)
-@@ -3332,12 +3450,15 @@
-
- for (v = variables; v; v = v->next)
- {
-- outf_p f = get_output_file_with_visibility (v->line.file);
-+ outf_p f = NULL;
- struct flist *fli;
- const char *length = NULL;
- int deletable_p = 0;
- options_p o;
--
-+ if (nb_plugin_files > 0 && plugin_output_filename && v->inplugin)
-+ f = plugin_output;
-+ else
-+ f = get_output_file_with_visibility (v->line.file);
- for (o = v->opt; o; o = o->next)
- if (strcmp (o->name, "length") == 0)
- length = o->info;
-@@ -3629,6 +3750,74 @@
- do_typedef (astratname, new_structure (astratname, 0, pos, field, 0), pos);
- }
-
-+
-+/* in plugin mode, the write of functions for structure is delayed to
-+ the end; we keep a vector of these */
-+struct delayedstructfunc_st
-+{
-+ type_p dly_s;
-+ const struct write_types_data* dly_wtd;
-+};
-+static struct delayedstructfunc_st* dlystructab;
-+static int dlystructsiz;
-+static int dlystructcnt;
-+
-+
-+
-+
-+static void
-+delay_func_for_structure (type_p s, const struct write_types_data* wtd)
-+{
-+ gcc_assert (s != NULL);
-+ gcc_assert (wtd != NULL);
-+ if (dlystructcnt + 1 >= dlystructsiz)
-+ {
-+ struct delayedstructfunc_st* oldtab = dlystructab;
-+ int oldsiz = dlystructsiz;
-+ int newsiz = (32 + oldsiz) * 2;
-+ int i = 0;
-+ gcc_assert (newsiz > dlystructcnt);
-+ dlystructab = XNEWVEC(struct delayedstructfunc_st, newsiz);
-+ for (i = 0; i < dlystructcnt; i++)
-+ dlystructab[i] = oldtab[i];
-+ for (i = dlystructcnt; i < newsiz; i++)
-+ {
-+ dlystructab[i].dly_s = NULL;
-+ dlystructab[i].dly_wtd = NULL;
-+ }
-+ dlystructsiz = newsiz;
-+ free (oldtab);
-+ }
-+ dlystructab[dlystructcnt].dly_s = s;
-+ dlystructab[dlystructcnt].dly_wtd = wtd;
-+ dlystructcnt++;
-+}
-+
-+
-+static void
-+output_delayed_functions(void)
-+{
-+ int i = 0;
-+ gcc_assert (plugin_output);
-+ for (i = 0; ikind == TYPE_LANG_STRUCT)
-+ {
-+ type_p ss;
-+ for (ss = s->u.s.lang_struct; ss; ss = ss->next)
-+ write_func_for_structure (s, ss, NULL, wtd);
-+ }
-+ else
-+ write_func_for_structure (s, s, NULL, wtd);
-+ }
-+ free (dlystructab);
-+ dlystructab = NULL;
-+ dlystructcnt = dlystructsiz = 0;
-+}
-+
-
- int
- main (int argc, char **argv)
-@@ -3639,20 +3828,23 @@
- /* fatal uses this */
- progname = "gengtype";
-
-- if (argc >= 5 && !strcmp (argv[1], "-p"))
-+ if (argc >= 6 && !strcmp (argv[1], "-P"))
- {
-- srcdir = argv[2];
-- inputlist = argv[3];
-- plugin_files = argv+4;
-- nb_plugin_files = argc-4;
-+ plugin_output_filename = argv[2];
-+ plugin_output = create_file ("GCC", plugin_output_filename);
-+ srcdir = argv[3];
-+ inputlist = argv[4];
-+ plugin_files = argv + 5;
-+ nb_plugin_files = argc - 5;
- }
-+
- else if (argc == 3)
- {
- srcdir = argv[1];
- inputlist = argv[2];
- }
- else
-- fatal ("usage: gengtype [-p] srcdir input-list [file1 file2 ... fileN]");
-+ fatal ("usage: gengtype [-P pluginout.h] srcdir input-list [file1 file2 ... fileN]");
-
- srcdir_len = strlen (srcdir);
-
-@@ -3678,9 +3870,14 @@
- do_scalar_typedef ("void", &pos); pos.line++;
- do_typedef ("PTR", create_pointer (resolve_typedef ("void", &pos)), &pos);
-
-- for (i = 0; i < num_gt_files; i++)
-- parse_file (gt_files[i]);
--
-+ for (i = 0; i < num_gt_files; i++)
-+ {
-+ is_plugin_file = first_plugin_file_ix >= 0
-+ && (int)i >= first_plugin_file_ix;
-+ parse_file (gt_files[i]);
-+ is_plugin_file = false;
-+ }
-+
- if (hit_error)
- return 1;
-
-@@ -3693,6 +3890,10 @@
- write_local (structures, param_structs);
- write_roots (variables);
- write_rtx_next ();
-+
-+ if (plugin_output)
-+ output_delayed_functions ();
-+
- close_output_files ();
-
- if (hit_error)
-Index: lto/gcc/gengtype.h
-===================================================================
---- lto.orig/gcc/gengtype.h 2009-09-01 00:16:27.942856818 +0200
-+++ lto/gcc/gengtype.h 2009-09-01 10:21:15.728775623 +0200
-@@ -76,6 +76,9 @@
- extern void parse_file (const char *name);
- extern bool hit_error;
-
-+/* flag set when parsing a plugin file */
-+extern bool is_plugin_file;
-+
- /* Token codes. */
- enum {
- EOF_TOKEN = 0,
From daniel at zuster.org Mon Sep 14 10:27:43 2009
From: daniel at zuster.org (Daniel Dunbar)
Date: Mon, 14 Sep 2009 15:27:43 -0000
Subject: [llvm-commits] [llvm] r81764 - /llvm/trunk/test/Makefile
Message-ID: <200909141527.n8EFRiqq018327@zion.cs.uiuc.edu>
Author: ddunbar
Date: Mon Sep 14 10:27:43 2009
New Revision: 81764
URL: http://llvm.org/viewvc/llvm-project?rev=81764&view=rev
Log:
Add a VALGRIND_EXTRA_ARGS makefile variable, with the obvious semantics.
Modified:
llvm/trunk/test/Makefile
Modified: llvm/trunk/test/Makefile
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Makefile?rev=81764&r1=81763&r2=81764&view=diff
==============================================================================
--- llvm/trunk/test/Makefile (original)
+++ llvm/trunk/test/Makefile Mon Sep 14 10:27:43 2009
@@ -43,7 +43,7 @@
endif
ifdef VG
-VALGRIND := valgrind --tool=memcheck --quiet --trace-children=yes --error-exitcode=3 --leak-check=full
+VALGRIND := valgrind --tool=memcheck --quiet --trace-children=yes --error-exitcode=3 --leak-check=full $(VALGRIND_EXTRA_ARGS)
endif
IGNORE_TESTS :=
From baldrick at free.fr Mon Sep 14 10:44:04 2009
From: baldrick at free.fr (Duncan Sands)
Date: Mon, 14 Sep 2009 15:44:04 -0000
Subject: [llvm-commits] [gcc-plugin] r81765 - /gcc-plugin/trunk/Makefile
Message-ID: <200909141544.n8EFi46a020800@zion.cs.uiuc.edu>
Author: baldrick
Date: Mon Sep 14 10:44:04 2009
New Revision: 81765
URL: http://llvm.org/viewvc/llvm-project?rev=81765&view=rev
Log:
Don't remove gt-llvm-cache.h when doing "make clean"
now that we distribute this file rather than always
generating it.
Modified:
gcc-plugin/trunk/Makefile
Modified: gcc-plugin/trunk/Makefile
URL: http://llvm.org/viewvc/llvm-project/gcc-plugin/trunk/Makefile?rev=81765&r1=81764&r2=81765&view=diff
==============================================================================
--- gcc-plugin/trunk/Makefile (original)
+++ gcc-plugin/trunk/Makefile Mon Sep 14 10:44:04 2009
@@ -40,4 +40,4 @@
sed -i "s/ggc_root_tab .*\[\]/ggc_root_tab gt_pch_rc__gt_llvm_cache_h[]/" $(GENGTYPE_OUTPUT)
clean::
- rm -f *.o *.so $(ARCH_DIR)/*.o $(GENGTYPE_OUTPUT)
+ rm -f *.o *.so $(ARCH_DIR)/*.o
From gohman at apple.com Mon Sep 14 10:54:19 2009
From: gohman at apple.com (Dan Gohman)
Date: Mon, 14 Sep 2009 08:54:19 -0700
Subject: [llvm-commits] Static Profile Patch
In-Reply-To:
References:
Message-ID: <030E9AA3-1AF1-433F-8807-9628E7155939@apple.com>
Hi Andrei,
Here are some review comments for this patch. I think it would be
fine to check into the tree at this point, so that future changes can
be reviewed incrementally instead of with monolithic patches.
BranchPredictionPass has
double getEdgeProbability(Edge &edge) const;
as a public member function, but Edge is a private typedef, so one of
these has the wrong visibility.
The passes should override the Pass::releaseMemory virtual function.
Some currently have a Clear member function; they should implement
releaseMemory and have it call Clear, or perhaps Clear should be
renamed releaseMemory, depending on how it's used.
lib/Analysis/BranchPredictionPass.cpp has
#include "llvm/Transforms/Utils/BasicBlockUtils.h"
which is a red flag because lib/Analysis code is not allowed to
depend on lib/Transforms code. However, this #include appears to be
unneeded, so it should be removed.
BranchHeuristicsInfo::MatchCallHeuristic and some of the others
don't test whether the terminator is a BranchInst. It looks like
there's nothing preventing them from analyzing a block with an
InvokeInst as its terminator. Is that intended by the heuristics?
BranchHeuristicsInfo::postDominates calls
PostDominatorTree::properlyDominates. Since the distinction between
domination and proper domination is often both subtle and critical
for algorithm correctness, please either rename this function or add
comments or both.
BranchPredictionInfo::FindBackEdges does a DominatorTree query for
every edge in the function. It would be possible to get a close
approximation of this using LoopInfo. That would miss unnatural
loops and spaghetti code though; is that the reason for doing the
full traversal? Please add a comment about this.
BranchPredictionInfo::FindExitEdges seems to be redundant with
Loop::getExitEdges.
Could BranchPredictionInfo::FindStores and FindCalls be combined
to avoid doing so many function traversals?
In its current form, BranchPredictionPass won't be usable in LLVM's
default optimization pipeline because it requires post-dominator tree
construction. None of LLVM's current default optimization passes
require post-dominator trees, so constructing it just for this pass
will likely be too slow. It could possibly be justified for -O3,
if there are sufficient benefits to oughtweigh the costs. There are
many LLVM users that don't use the standard -O2 or -O3 passes
also, of course.
Dan
On Sep 11, 2009, at 6:46 PM, Andrei Alvares wrote:
> Hello everyone,
> Since this patch hasn't been applied yet, I'm taking the liberty
> to send a more updated version. I made several changes in the branch
> predictor (BranchPredictionPass) and in the intra procedural static
> profiler (BlockEdgeFrequencyPass).
> Attachment: stprof-11.09.09.patch.
>
> While I was debbuging the code, I've noticed that I was
> maintaining data across multiple calls of runOnFunction on both
> passes, which was indeed an undesirable behavior. After cleaning up,
> both passes shown improved results. In fact, the branch predictor
> produced very close related prediction as Ball's predictor. I ran
> the branch predictor on the SPEC 2000 (int and float). I'm attaching
> "heuristics.txt" which compared results separated by heuristic for
> both predictors. While most heuristics predicted more accurately,
> the call and opcode heuristics shown worst results. This means that
> is still space for improvements. Also, I've found a bug in the way
> the predictor threats a branch that have some backedge sucessors,
> but not all. I expected that the other branches were always exit
> edges, but there are cases that this situation is not true.
>
> Moreover, while calculating blocks and edge frequencies it is
> possible to verify if it is calculating correct frequency
> information. Since the entry block frequency is always one, is
> expected that the exit's total frequency is also one. So, all we
> need to do is check the sum of all predecessors edges of exit's
> basic blocks to match one. However, I've found two cases of
> miscalculation by the pass: (1) when the control flow graph is not
> reducible; (2) when seems to be a loop that does not terminates (has
> no exit blocks). Although this pass can calculate frequencies for
> those situations, it might not be accurate. Nevertheless, seems like
> the pass is doing what is supposed to.
>
> The global static profiler (inter procedural) is not as accurate
> as Wu's paper yet. But after those fixes, it has improved quite
> significantly. I'm attaching the results of the profiler comparing
> the correct prediction rate of the top most executed blocks, edges,
> and function call invocations (ranging from 10% to 50%).
> Attachments: block.txt, edge.txt and call.txt.
>
> Thanks,
> Andrei
>
> On Wed, Sep 2, 2009 at 3:37 PM, Andrei Alvares
> wrote:
> Hello everyone,
> Here it follows the static profiler implementation, developed as
> part of my google summer of code project. It performs branch
> predictions in compilation time, i.e., assign probabilities to branch
> outcomes using a set of predefined heuristics. Also, it calculates
> intra and interprocedural profiling by staticly estimate basic blocks
> and edges frequencies (local and global) and function call invocations
> frequencies.
> Attachment: stprof-02.02.09.patch
>
> I've run the static profiler on some of the SPECint 2000 programs
> (those that I was able to compile and run). It has not yet achieved
> the accuracy found in Wu's paper, but I believe it can still be
> improved.
> Best regards,
> Andrei
>
> Youfeng Wu and James R. Larus. Static branch frequency and program
> profile analysis. In MICRO 27: Proceedings of the 27th annual
> international symposium on Microarchitecture. IEEE, 1994.
>
> <
> heuristics
> .txt
> >
> <
> blocks
> .txt
> >
> <
> edge
> .txt
> >
> <
> call
> .txt
> >
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From daniel at zuster.org Mon Sep 14 11:10:32 2009
From: daniel at zuster.org (Daniel Dunbar)
Date: Mon, 14 Sep 2009 16:10:32 -0000
Subject: [llvm-commits] [llvm] r81766 - in /llvm/trunk/utils/valgrind: ./
x86_64-pc-linux-gnu_gcc-4.3.3.supp
Message-ID: <200909141610.n8EGAWdQ024254@zion.cs.uiuc.edu>
Author: ddunbar
Date: Mon Sep 14 11:10:32 2009
New Revision: 81766
URL: http://llvm.org/viewvc/llvm-project?rev=81766&view=rev
Log:
Add a valgrind suppressions file for x86_64/linux/4.3.3.
Added:
llvm/trunk/utils/valgrind/
llvm/trunk/utils/valgrind/x86_64-pc-linux-gnu_gcc-4.3.3.supp
Added: llvm/trunk/utils/valgrind/x86_64-pc-linux-gnu_gcc-4.3.3.supp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/utils/valgrind/x86_64-pc-linux-gnu_gcc-4.3.3.supp?rev=81766&view=auto
==============================================================================
--- llvm/trunk/utils/valgrind/x86_64-pc-linux-gnu_gcc-4.3.3.supp (added)
+++ llvm/trunk/utils/valgrind/x86_64-pc-linux-gnu_gcc-4.3.3.supp Mon Sep 14 11:10:32 2009
@@ -0,0 +1,23 @@
+{
+ libstdcxx_overlapped_memcpy_in_stable_sort_1
+ Memcheck:Overlap
+ fun:memcpy
+ ...
+ fun:_ZSt11stable_sortIN9__gnu_cxx17__normal_iteratorIPSt4pairIPKN4llvm5ValueEjESt6vectorIS7_SaIS7_EEEEN12_GLOBAL__N_116CstSortPredicateEEvT_SF_T0_
+}
+
+{
+ libstdcxx_overlapped_memcpy_in_stable_sort_2
+ Memcheck:Overlap
+ fun:memcpy
+ ...
+ fun:_ZSt11stable_sortIN9__gnu_cxx17__normal_iteratorIPSt4pairIPKN4llvm5ValueEjESt6vectorIS7_SaIS7_EEEEN12_GLOBAL__N_116CstSortPredicateEEvT_SF_T0_
+}
+
+{
+ libstdcxx_overlapped_memcpy_in_stable_sort_3
+ Memcheck:Overlap
+ fun:memcpy
+ ...
+ fun:_ZSt11stable_sortIN9__gnu_cxx17__normal_iteratorIPSt4pairIPKN4llvm4TypeEjESt6vectorIS7_SaIS7_EEEEPFbRKS7_SE_EEvT_SH_T0_
+}
From echristo at apple.com Mon Sep 14 11:38:49 2009
From: echristo at apple.com (Eric Christopher)
Date: Mon, 14 Sep 2009 16:38:49 -0000
Subject: [llvm-commits] [llvm] r81768 - in /llvm/trunk:
autoconf/configure.ac configure
Message-ID: <200909141638.n8EGcoZJ028249@zion.cs.uiuc.edu>
Author: echristo
Date: Mon Sep 14 11:38:49 2009
New Revision: 81768
URL: http://llvm.org/viewvc/llvm-project?rev=81768&view=rev
Log:
Enable the jit for llvm-config.
Patch by Xerxes R?nby!
Modified:
llvm/trunk/autoconf/configure.ac
llvm/trunk/configure
Modified: llvm/trunk/autoconf/configure.ac
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/autoconf/configure.ac?rev=81768&r1=81767&r2=81768&view=diff
==============================================================================
--- llvm/trunk/autoconf/configure.ac (original)
+++ llvm/trunk/autoconf/configure.ac Mon Sep 14 11:38:49 2009
@@ -396,7 +396,7 @@
PowerPC) AC_SUBST(TARGET_HAS_JIT,1) ;;
x86_64) AC_SUBST(TARGET_HAS_JIT,1) ;;
Alpha) AC_SUBST(TARGET_HAS_JIT,1) ;;
- ARM) AC_SUBST(TARGET_HAS_JIT,0) ;;
+ ARM) AC_SUBST(TARGET_HAS_JIT,1) ;;
Mips) AC_SUBST(TARGET_HAS_JIT,0) ;;
PIC16) AC_SUBST(TARGET_HAS_JIT,0) ;;
XCore) AC_SUBST(TARGET_HAS_JIT,0) ;;
Modified: llvm/trunk/configure
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/configure?rev=81768&r1=81767&r2=81768&view=diff
==============================================================================
--- llvm/trunk/configure (original)
+++ llvm/trunk/configure Mon Sep 14 11:38:49 2009
@@ -4902,7 +4902,7 @@
;;
Alpha) TARGET_HAS_JIT=1
;;
- ARM) TARGET_HAS_JIT=0
+ ARM) TARGET_HAS_JIT=1
;;
Mips) TARGET_HAS_JIT=0
;;
From sabre at nondot.org Mon Sep 14 11:49:26 2009
From: sabre at nondot.org (Chris Lattner)
Date: Mon, 14 Sep 2009 16:49:26 -0000
Subject: [llvm-commits] [llvm] r81770 - /llvm/trunk/lib/Target/README.txt
Message-ID: <200909141649.n8EGnQnb029947@zion.cs.uiuc.edu>
Author: lattner
Date: Mon Sep 14 11:49:26 2009
New Revision: 81770
URL: http://llvm.org/viewvc/llvm-project?rev=81770&view=rev
Log:
add PR#
Modified:
llvm/trunk/lib/Target/README.txt
Modified: llvm/trunk/lib/Target/README.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/README.txt?rev=81770&r1=81769&r2=81770&view=diff
==============================================================================
--- llvm/trunk/lib/Target/README.txt (original)
+++ llvm/trunk/lib/Target/README.txt Mon Sep 14 11:49:26 2009
@@ -1653,6 +1653,7 @@
Instcombine should be able to optimize away the loads (and thus the globals).
+See also PR4973
//===---------------------------------------------------------------------===//
From baldrick at free.fr Mon Sep 14 12:19:46 2009
From: baldrick at free.fr (Duncan Sands)
Date: Mon, 14 Sep 2009 17:19:46 -0000
Subject: [llvm-commits] [gcc-plugin] r81772 -
/gcc-plugin/trunk/llvm-backend.cpp
Message-ID: <200909141719.n8EHJkBF001549@zion.cs.uiuc.edu>
Author: baldrick
Date: Mon Sep 14 12:19:45 2009
New Revision: 81772
URL: http://llvm.org/viewvc/llvm-project?rev=81772&view=rev
Log:
Turn off a bunch more GCC optimizations (there are more we might want to turn off,
but this is most of them). In particular, by turning off function cloning this
works around GCC bug 41355, which was firing an assertion in EmitCallOf. With
these changes sqlite3 compiles at all optimization levels.
Modified:
gcc-plugin/trunk/llvm-backend.cpp
Modified: gcc-plugin/trunk/llvm-backend.cpp
URL: http://llvm.org/viewvc/llvm-project/gcc-plugin/trunk/llvm-backend.cpp?rev=81772&r1=81771&r2=81772&view=diff
==============================================================================
--- gcc-plugin/trunk/llvm-backend.cpp (original)
+++ gcc-plugin/trunk/llvm-backend.cpp Mon Sep 14 12:19:45 2009
@@ -1992,6 +1992,32 @@
}
};
+/// pass_ipa_null - IPA pass that does nothing.
+static struct ipa_opt_pass_d pass_ipa_null = {
+ {
+ IPA_PASS,
+ NULL, /* name */
+ gate_null, /* gate */
+ NULL, /* execute */
+ NULL, /* sub */
+ NULL, /* next */
+ 0, /* static_pass_number */
+ TV_NONE, /* tv_id */
+ 0, /* properties_required */
+ 0, /* properties_provided */
+ 0, /* properties_destroyed */
+ 0, /* todo_flags_start */
+ 0 /* todo_flags_finish */
+ },
+ NULL, /* generate_summary */
+ NULL, /* write_summary */
+ NULL, /* read_summary */
+ NULL, /* function_read_summary */
+ 0, /* TODOs */
+ NULL, /* function_transform */
+ NULL /* variable_transform */
+};
+
/// pass_rtl_null - RTL pass that does nothing.
static struct rtl_opt_pass pass_rtl_null =
{
@@ -2012,6 +2038,26 @@
}
};
+/// pass_simple_ipa_null - Simple IPA pass that does nothing.
+static struct simple_ipa_opt_pass pass_simple_ipa_null =
+{
+ {
+ SIMPLE_IPA_PASS,
+ NULL, /* name */
+ gate_null, /* gate */
+ NULL, /* execute */
+ NULL, /* sub */
+ NULL, /* next */
+ 0, /* static_pass_number */
+ TV_NONE, /* tv_id */
+ 0, /* properties_required */
+ 0, /* properties_provided */
+ 0, /* properties_destroyed */
+ 0, /* todo_flags_start */
+ 0 /* todo_flags_finish */
+ }
+};
+
// Garbage collector roots.
extern const struct ggc_cache_tab gt_ggc_rc__gt_llvm_cache_h[];
@@ -2114,6 +2160,85 @@
// TODO: figure out a good way of turning off ipa optimization passes.
// Could just set optimize to zero (after taking a copy), but this would
// also impact front-end optimizations.
+
+ // Turn off pass_ipa_early_inline.
+ pass_info.pass = &pass_simple_ipa_null.pass;
+ pass_info.reference_pass_name = "einline_ipa";
+ pass_info.ref_pass_instance_number = 0;
+ pass_info.pos_op = PASS_POS_REPLACE;
+ register_callback (plugin_name, PLUGIN_PASS_MANAGER_SETUP, NULL, &pass_info);
+
+ // Turn off pass_all_early_optimizations.
+ pass_info.pass = &pass_gimple_null.pass;
+ pass_info.reference_pass_name = "early_optimizations";
+ pass_info.ref_pass_instance_number = 0;
+ pass_info.pos_op = PASS_POS_REPLACE;
+ register_callback (plugin_name, PLUGIN_PASS_MANAGER_SETUP, NULL, &pass_info);
+
+ // Turn off pass_ipa_increase_alignment.
+ pass_info.pass = &pass_simple_ipa_null.pass;
+ pass_info.reference_pass_name = "increase_alignment";
+ pass_info.ref_pass_instance_number = 0;
+ pass_info.pos_op = PASS_POS_REPLACE;
+ register_callback (plugin_name, PLUGIN_PASS_MANAGER_SETUP, NULL, &pass_info);
+
+ // Turn off pass_ipa_matrix_reorg.
+ pass_info.pass = &pass_simple_ipa_null.pass;
+ pass_info.reference_pass_name = "matrix-reorg";
+ pass_info.ref_pass_instance_number = 0;
+ pass_info.pos_op = PASS_POS_REPLACE;
+ register_callback (plugin_name, PLUGIN_PASS_MANAGER_SETUP, NULL, &pass_info);
+
+ // Turn off pass_ipa_cp.
+ pass_info.pass = &pass_ipa_null.pass;
+ pass_info.reference_pass_name = "cp";
+ pass_info.ref_pass_instance_number = 0;
+ pass_info.pos_op = PASS_POS_REPLACE;
+ register_callback (plugin_name, PLUGIN_PASS_MANAGER_SETUP, NULL, &pass_info);
+
+ // Turn off pass_ipa_inline.
+ pass_info.pass = &pass_ipa_null.pass;
+ pass_info.reference_pass_name = "inline";
+ pass_info.ref_pass_instance_number = 0;
+ pass_info.pos_op = PASS_POS_REPLACE;
+ register_callback (plugin_name, PLUGIN_PASS_MANAGER_SETUP, NULL, &pass_info);
+
+ // Turn off pass_ipa_reference.
+ pass_info.pass = &pass_ipa_null.pass;
+ pass_info.reference_pass_name = "static-var";
+ pass_info.ref_pass_instance_number = 0;
+ pass_info.pos_op = PASS_POS_REPLACE;
+ register_callback (plugin_name, PLUGIN_PASS_MANAGER_SETUP, NULL, &pass_info);
+
+ // Turn off pass_ipa_pure_const.
+ pass_info.pass = &pass_ipa_null.pass;
+ pass_info.reference_pass_name = "pure-const";
+ pass_info.ref_pass_instance_number = 0;
+ pass_info.pos_op = PASS_POS_REPLACE;
+ register_callback (plugin_name, PLUGIN_PASS_MANAGER_SETUP, NULL, &pass_info);
+
+ // Turn off pass_ipa_type_escape.
+ pass_info.pass = &pass_simple_ipa_null.pass;
+ pass_info.reference_pass_name = "type-escape-var";
+ pass_info.ref_pass_instance_number = 0;
+ pass_info.pos_op = PASS_POS_REPLACE;
+ register_callback (plugin_name, PLUGIN_PASS_MANAGER_SETUP, NULL, &pass_info);
+
+ // Turn off pass_ipa_pta.
+ pass_info.pass = &pass_simple_ipa_null.pass;
+ pass_info.reference_pass_name = "pta";
+ pass_info.ref_pass_instance_number = 0;
+ pass_info.pos_op = PASS_POS_REPLACE;
+ register_callback (plugin_name, PLUGIN_PASS_MANAGER_SETUP, NULL, &pass_info);
+
+ // Turn off pass_ipa_struct_reorg.
+ pass_info.pass = &pass_simple_ipa_null.pass;
+ pass_info.reference_pass_name = "ipa_struct_reorg";
+ pass_info.ref_pass_instance_number = 0;
+ pass_info.pos_op = PASS_POS_REPLACE;
+ register_callback (plugin_name, PLUGIN_PASS_MANAGER_SETUP, NULL, &pass_info);
+
+ // Turn off pass_all_optimizations.
pass_info.pass = &pass_gimple_null.pass;
pass_info.reference_pass_name = "*all_optimizations";
pass_info.ref_pass_instance_number = 0;
From grosbach at apple.com Mon Sep 14 12:27:35 2009
From: grosbach at apple.com (Jim Grosbach)
Date: Mon, 14 Sep 2009 17:27:35 -0000
Subject: [llvm-commits] [llvm] r81773 -
/llvm/trunk/lib/Target/ARM/ARMTargetMachine.cpp
Message-ID: <200909141727.n8EHRa2X002525@zion.cs.uiuc.edu>
Author: grosbach
Date: Mon Sep 14 12:27:35 2009
New Revision: 81773
URL: http://llvm.org/viewvc/llvm-project?rev=81773&view=rev
Log:
trivial whitespace cleanup
Modified:
llvm/trunk/lib/Target/ARM/ARMTargetMachine.cpp
Modified: llvm/trunk/lib/Target/ARM/ARMTargetMachine.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMTargetMachine.cpp?rev=81773&r1=81772&r2=81773&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMTargetMachine.cpp (original)
+++ llvm/trunk/lib/Target/ARM/ARMTargetMachine.cpp Mon Sep 14 12:27:35 2009
@@ -28,7 +28,7 @@
cl::desc("Disable if-conversion pass"));
static const MCAsmInfo *createMCAsmInfo(const Target &T,
- const StringRef &TT) {
+ const StringRef &TT) {
Triple TheTriple(TT);
switch (TheTriple.getOS()) {
case Triple::Darwin:
@@ -43,7 +43,7 @@
// Register the target.
RegisterTargetMachine X(TheARMTarget);
RegisterTargetMachine Y(TheThumbTarget);
-
+
// Register the target asm info.
RegisterAsmInfoFn A(TheARMTarget, createMCAsmInfo);
RegisterAsmInfoFn B(TheThumbTarget, createMCAsmInfo);
From gohman at apple.com Mon Sep 14 15:40:10 2009
From: gohman at apple.com (Dan Gohman)
Date: Mon, 14 Sep 2009 20:40:10 -0000
Subject: [llvm-commits] [llvm] r81782 -
/llvm/trunk/include/llvm/CodeGen/MachineMemOperand.h
Message-ID: <200909142040.n8EKeAeI028387@zion.cs.uiuc.edu>
Author: djg
Date: Mon Sep 14 15:40:10 2009
New Revision: 81782
URL: http://llvm.org/viewvc/llvm-project?rev=81782&view=rev
Log:
Update a comment to match the source. PseudoSourceValues are now
obtained via accessor functions.
Modified:
llvm/trunk/include/llvm/CodeGen/MachineMemOperand.h
Modified: llvm/trunk/include/llvm/CodeGen/MachineMemOperand.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/CodeGen/MachineMemOperand.h?rev=81782&r1=81781&r2=81782&view=diff
==============================================================================
--- llvm/trunk/include/llvm/CodeGen/MachineMemOperand.h (original)
+++ llvm/trunk/include/llvm/CodeGen/MachineMemOperand.h Mon Sep 14 15:40:10 2009
@@ -51,10 +51,13 @@
MachineMemOperand(const Value *v, unsigned int f, int64_t o, uint64_t s,
unsigned int a);
- /// getValue - Return the base address of the memory access.
- /// Special values are PseudoSourceValue::FPRel, PseudoSourceValue::SPRel,
- /// and the other PseudoSourceValue members which indicate references to
- /// frame/stack pointer relative references and other special references.
+ /// getValue - Return the base address of the memory access. This may either
+ /// be a normal LLVM IR Value, or one of the special values used in CodeGen.
+ /// Special values are those obtained via
+ /// PseudoSourceValue::getFixedStack(int), PseudoSourceValue::getStack, and
+ /// other PseudoSourceValue member functions which return objects which stand
+ /// for frame/stack pointer relative references and other special references
+ /// which are not representable in the high-level IR.
const Value *getValue() const { return V; }
/// getFlags - Return the raw flags of the source value, \see MemOperandFlags.
From isanbard at gmail.com Mon Sep 14 15:52:38 2009
From: isanbard at gmail.com (Bill Wendling)
Date: Mon, 14 Sep 2009 20:52:38 -0000
Subject: [llvm-commits] [llvm] r81785 -
/llvm/trunk/lib/CodeGen/DwarfEHPrepare.cpp
Message-ID: <200909142052.n8EKqcK0030132@zion.cs.uiuc.edu>
Author: void
Date: Mon Sep 14 15:52:37 2009
New Revision: 81785
URL: http://llvm.org/viewvc/llvm-project?rev=81785&view=rev
Log:
Pull the creation of the "RewindFunction" function out of the loop. It's only
created once, so shouldn't be stuck in the middle of the loop. Also early exit
if there are no uses of UnwindInst in the function.
Modified:
llvm/trunk/lib/CodeGen/DwarfEHPrepare.cpp
Modified: llvm/trunk/lib/CodeGen/DwarfEHPrepare.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/DwarfEHPrepare.cpp?rev=81785&r1=81784&r2=81785&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/DwarfEHPrepare.cpp (original)
+++ llvm/trunk/lib/CodeGen/DwarfEHPrepare.cpp Mon Sep 14 15:52:37 2009
@@ -219,29 +219,40 @@
/// at runtime if there is no such exception: using unwind to throw a new
/// exception is currently not supported.
bool DwarfEHPrepare::LowerUnwinds() {
- bool Changed = false;
+ SmallVector UnwindInsts;
for (Function::iterator I = F->begin(), E = F->end(); I != E; ++I) {
TerminatorInst *TI = I->getTerminator();
- if (!isa(TI))
- continue;
+ if (isa(TI))
+ UnwindInsts.push_back(TI);
+ }
+
+ if (UnwindInsts.empty()) return false;
+
+ // Find the rewind function if we didn't already.
+ if (!RewindFunction) {
+ LLVMContext &Ctx = UnwindInsts[0]->getContext();
+ std::vector
+ Params(1, PointerType::getUnqual(Type::getInt8Ty(Ctx)));
+ FunctionType *FTy = FunctionType::get(Type::getVoidTy(Ctx),
+ Params, false);
+ const char *RewindName = TLI->getLibcallName(RTLIB::UNWIND_RESUME);
+ RewindFunction = F->getParent()->getOrInsertFunction(RewindName, FTy);
+ }
+
+ bool Changed = false;
+
+ for (SmallVectorImpl::iterator
+ I = UnwindInsts.begin(), E = UnwindInsts.end(); I != E; ++I) {
+ TerminatorInst *TI = *I;
// Replace the unwind instruction with a call to _Unwind_Resume (or the
// appropriate target equivalent) followed by an UnreachableInst.
- // Find the rewind function if we didn't already.
- if (!RewindFunction) {
- std::vector Params(1,
- PointerType::getUnqual(Type::getInt8Ty(TI->getContext())));
- FunctionType *FTy = FunctionType::get(Type::getVoidTy(TI->getContext()),
- Params, false);
- const char *RewindName = TLI->getLibcallName(RTLIB::UNWIND_RESUME);
- RewindFunction = F->getParent()->getOrInsertFunction(RewindName, FTy);
- }
-
// Create the call...
CallInst *CI = CallInst::Create(RewindFunction,
- CreateReadOfExceptionValue(I), "", TI);
+ CreateReadOfExceptionValue(TI->getParent()),
+ "", TI);
CI->setCallingConv(TLI->getLibcallCallingConv(RTLIB::UNWIND_RESUME));
// ...followed by an UnreachableInst.
new UnreachableInst(TI->getContext(), TI);
From echristo at apple.com Mon Sep 14 16:13:49 2009
From: echristo at apple.com (Eric Christopher)
Date: Mon, 14 Sep 2009 21:13:49 -0000
Subject: [llvm-commits] [llvm-gcc-4.2] r81788 -
/llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C
Message-ID: <200909142113.n8ELDnQK000590@zion.cs.uiuc.edu>
Author: echristo
Date: Mon Sep 14 16:13:49 2009
New Revision: 81788
URL: http://llvm.org/viewvc/llvm-project?rev=81788&view=rev
Log:
Update this test, the except table is now in the data section.
Modified:
llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C
Modified: llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/testsuite/g%2B%2B.apple/eh1.C?rev=81788&r1=81787&r2=81788&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C (original)
+++ llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C Mon Sep 14 16:13:49 2009
@@ -1,6 +1,6 @@
-/* APPLE LOCAL file EH __TEXT __gcc_except_tab 5819051 */
+/* APPLE LOCAL file EH __DATA __gcc_except_tab 5819051 */
/* { dg-do compile { target *-*-darwin* } } */
-/* { dg-final { scan-assembler "section __TEXT,__gcc_except_tab" } } */
+/* { dg-final { scan-assembler "__DATA,__gcc_except_tab" } } */
/* Radar 5819051 */
#include
From clattner at apple.com Mon Sep 14 16:31:59 2009
From: clattner at apple.com (Chris Lattner)
Date: Mon, 14 Sep 2009 14:31:59 -0700
Subject: [llvm-commits] [llvm-gcc-4.2] r81788 -
/llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C
In-Reply-To: <200909142113.n8ELDnQK000590@zion.cs.uiuc.edu>
References: <200909142113.n8ELDnQK000590@zion.cs.uiuc.edu>
Message-ID:
On Sep 14, 2009, at 2:13 PM, Eric Christopher wrote:
> Author: echristo
> Date: Mon Sep 14 16:13:49 2009
> New Revision: 81788
>
> URL: http://llvm.org/viewvc/llvm-project?rev=81788&view=rev
> Log:
> Update this test, the except table is now in the data section.
But that is a "bug", so we want the test to continue failing?
-Chris
>
> Modified:
> llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C
>
> Modified: llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C
> URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/testsuite/g%2B%2B.apple/eh1.C?rev=81788&r1=81787&r2=81788&view=diff
>
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C (original)
> +++ llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C Mon Sep 14
> 16:13:49 2009
> @@ -1,6 +1,6 @@
> -/* APPLE LOCAL file EH __TEXT __gcc_except_tab 5819051 */
> +/* APPLE LOCAL file EH __DATA __gcc_except_tab 5819051 */
> /* { dg-do compile { target *-*-darwin* } } */
> -/* { dg-final { scan-assembler "section
> __TEXT,__gcc_except_tab" } } */
> +/* { dg-final { scan-assembler "__DATA,__gcc_except_tab" } } */
> /* Radar 5819051 */
>
> #include
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From evan.cheng at apple.com Mon Sep 14 16:33:43 2009
From: evan.cheng at apple.com (Evan Cheng)
Date: Mon, 14 Sep 2009 21:33:43 -0000
Subject: [llvm-commits] [llvm] r81796 - in /llvm/trunk:
include/llvm/CodeGen/LiveInterval.h
include/llvm/CodeGen/LiveIntervalAnalysis.h
lib/CodeGen/LiveIntervalAnalysis.cpp
Message-ID: <200909142133.n8ELXhcQ003245@zion.cs.uiuc.edu>
Author: evancheng
Date: Mon Sep 14 16:33:42 2009
New Revision: 81796
URL: http://llvm.org/viewvc/llvm-project?rev=81796&view=rev
Log:
Add early coalescing to liveintervals. This is work in progress and is known to miscompute some tests. Read it at your own rish, I have aged 10 year while writing this.
The gist of this is if source of some of the copies that feed into a phi join is defined by the phi join, we'd like to eliminate them. However, if any of the non-identity source overlaps the live interval of the phi join then the coalescer won't be able to coalesce them. The early coalescer's job is to eliminate the identity copies by partially-coalescing the two live intervals.
Modified:
llvm/trunk/include/llvm/CodeGen/LiveInterval.h
llvm/trunk/include/llvm/CodeGen/LiveIntervalAnalysis.h
llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp
Modified: llvm/trunk/include/llvm/CodeGen/LiveInterval.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/CodeGen/LiveInterval.h?rev=81796&r1=81795&r2=81796&view=diff
==============================================================================
--- llvm/trunk/include/llvm/CodeGen/LiveInterval.h (original)
+++ llvm/trunk/include/llvm/CodeGen/LiveInterval.h Mon Sep 14 16:33:42 2009
@@ -584,7 +584,6 @@
/// for the Value number.
VNInfo *createValueCopy(const VNInfo *orig,
BumpPtrAllocator &VNInfoAllocator) {
-
VNInfo *VNI =
static_cast(VNInfoAllocator.Allocate((unsigned)sizeof(VNInfo),
alignof()));
Modified: llvm/trunk/include/llvm/CodeGen/LiveIntervalAnalysis.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/CodeGen/LiveIntervalAnalysis.h?rev=81796&r1=81795&r2=81796&view=diff
==============================================================================
--- llvm/trunk/include/llvm/CodeGen/LiveIntervalAnalysis.h (original)
+++ llvm/trunk/include/llvm/CodeGen/LiveIntervalAnalysis.h Mon Sep 14 16:33:42 2009
@@ -65,9 +65,6 @@
AliasAnalysis *aa_;
LiveVariables* lv_;
-
-
-
/// Special pool allocator for VNInfo's (LiveInterval val#).
///
BumpPtrAllocator VNInfoAllocator;
@@ -94,9 +91,14 @@
DenseMap terminatorGaps;
+ /// phiJoinCopies - Copy instructions which are PHI joins.
+ SmallVector phiJoinCopies;
+
+ /// allocatableRegs_ - A bit vector of allocatable registers.
BitVector allocatableRegs_;
- std::vector ClonedMIs;
+ /// CloneMIs - A list of clones as result of re-materialization.
+ std::vector CloneMIs;
typedef LiveInterval::InstrSlots InstrSlots;
@@ -430,7 +432,14 @@
private:
/// computeIntervals - Compute live intervals.
void computeIntervals();
-
+
+ bool isProfitableToCoalesce(LiveInterval &DstInt, LiveInterval &SrcInt,
+ SmallVector &IdentCopies,
+ SmallVector &OtherCopies,
+ bool &HaveConflict);
+
+ void performEarlyCoalescing();
+
/// handleRegisterDef - update intervals for a register def
/// (calls handlePhysicalRegisterDef and
/// handleVirtualRegisterDef)
@@ -560,7 +569,8 @@
static LiveInterval* createInterval(unsigned Reg);
- void printRegName(unsigned reg) const;
+ void printInstrs(raw_ostream &O) const;
+ void dumpInstrs() const;
};
} // End llvm namespace
Modified: llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp?rev=81796&r1=81795&r2=81796&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp (original)
+++ llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp Mon Sep 14 16:33:42 2009
@@ -49,19 +49,20 @@
static cl::opt DisableReMat("disable-rematerialization",
cl::init(false), cl::Hidden);
-static cl::opt SplitAtBB("split-intervals-at-bb",
- cl::init(true), cl::Hidden);
-static cl::opt SplitLimit("split-limit",
- cl::init(-1), cl::Hidden);
-
static cl::opt EnableAggressiveRemat("aggressive-remat", cl::Hidden);
static cl::opt EnableFastSpilling("fast-spill",
cl::init(false), cl::Hidden);
-STATISTIC(numIntervals, "Number of original intervals");
-STATISTIC(numFolds , "Number of loads/stores folded into instructions");
-STATISTIC(numSplits , "Number of intervals split");
+static cl::opt EarlyCoalescing("early-coalescing", cl::init(false));
+
+static cl::opt CoalescingLimit("early-coalescing-limit",
+ cl::init(-1), cl::Hidden);
+
+STATISTIC(numIntervals , "Number of original intervals");
+STATISTIC(numFolds , "Number of loads/stores folded into instructions");
+STATISTIC(numSplits , "Number of intervals split");
+STATISTIC(numCoalescing, "Number of early coalescing performed");
char LiveIntervals::ID = 0;
static RegisterPass X("liveintervals", "Live Interval Analysis");
@@ -96,12 +97,13 @@
i2miMap_.clear();
r2iMap_.clear();
terminatorGaps.clear();
+ phiJoinCopies.clear();
// Release VNInfo memroy regions after all VNInfo objects are dtor'd.
VNInfoAllocator.Reset();
- while (!ClonedMIs.empty()) {
- MachineInstr *MI = ClonedMIs.back();
- ClonedMIs.pop_back();
+ while (!CloneMIs.empty()) {
+ MachineInstr *MI = CloneMIs.back();
+ CloneMIs.pop_back();
mf_->DeleteMachineInstr(MI);
}
}
@@ -264,6 +266,7 @@
mi2iMap_.clear();
i2miMap_.clear();
terminatorGaps.clear();
+ phiJoinCopies.clear();
FunctionSize = 0;
@@ -518,6 +521,7 @@
processImplicitDefs();
computeNumbering();
computeIntervals();
+ performEarlyCoalescing();
numIntervals += getNumIntervals();
@@ -533,6 +537,10 @@
OS << "\n";
}
+ printInstrs(OS);
+}
+
+void LiveIntervals::printInstrs(raw_ostream &OS) const {
OS << "********** MACHINEINSTRS **********\n";
for (MachineFunction::iterator mbbi = mf_->begin(), mbbe = mf_->end();
@@ -545,6 +553,10 @@
}
}
+void LiveIntervals::dumpInstrs() const {
+ printInstrs(errs());
+}
+
/// conflictsWithPhysRegDef - Returns true if the specified register
/// is defined during the duration of the specified interval.
bool LiveIntervals::conflictsWithPhysRegDef(const LiveInterval &li,
@@ -626,7 +638,7 @@
}
-void LiveIntervals::printRegName(unsigned reg) const {
+static void printRegName(unsigned reg, const TargetRegisterInfo* tri_) {
if (TargetRegisterInfo::isPhysicalRegister(reg))
errs() << tri_->getName(reg);
else
@@ -641,7 +653,7 @@
LiveInterval &interval) {
DEBUG({
errs() << "\t\tregister: ";
- printRegName(interval.reg);
+ printRegName(interval.reg, tri_);
});
// Virtual registers may be defined multiple times (due to phi
@@ -789,12 +801,10 @@
// first redefinition of the vreg that we have seen, go back and change
// the live range in the PHI block to be a different value number.
if (interval.containsOneValue()) {
- assert(vi.Kills.size() == 1 &&
- "PHI elimination vreg should have one kill, the PHI itself!");
-
// Remove the old range that we now know has an incorrect number.
VNInfo *VNI = interval.getValNumInfo(0);
MachineInstr *Killer = vi.Kills[0];
+ phiJoinCopies.push_back(Killer);
MachineInstrIndex Start = getMBBStartIdx(Killer->getParent());
MachineInstrIndex End =
getNextSlot(getUseIndex(getInstructionIndex(Killer)));
@@ -805,7 +815,7 @@
});
interval.removeRange(Start, End);
assert(interval.ranges.size() == 1 &&
- "newly discovered PHI interval has >1 ranges.");
+ "Newly discovered PHI interval has >1 ranges.");
MachineBasicBlock *killMBB = getMBBFromIndex(interval.endIndex());
VNI->addKill(terminatorGaps[killMBB]);
VNI->setHasPHIKill(true);
@@ -835,7 +845,7 @@
MachineInstrIndex defIndex = getDefIndex(MIIdx);
if (MO.isEarlyClobber())
defIndex = getUseIndex(MIIdx);
-
+
VNInfo *ValNo;
MachineInstr *CopyMI = NULL;
unsigned SrcReg, DstReg, SrcSubReg, DstSubReg;
@@ -868,7 +878,7 @@
// lifetime must end somewhere in its defining basic block.
DEBUG({
errs() << "\t\tregister: ";
- printRegName(interval.reg);
+ printRegName(interval.reg, tri_);
});
MachineInstrIndex baseIndex = MIIdx;
@@ -977,7 +987,7 @@
LiveInterval &interval, bool isAlias) {
DEBUG({
errs() << "\t\tlivein register: ";
- printRegName(interval.reg);
+ printRegName(interval.reg, tri_);
});
// Look for kills, if it reaches a def before it's killed, then it shouldn't
@@ -1039,6 +1049,138 @@
DEBUG(errs() << " +" << LR << '\n');
}
+bool
+LiveIntervals::isProfitableToCoalesce(LiveInterval &DstInt, LiveInterval &SrcInt,
+ SmallVector &IdentCopies,
+ SmallVector &OtherCopies,
+ bool &HaveConflict) {
+ HaveConflict = false;
+
+ unsigned NumIdent = 0;
+ unsigned NumSources = 0;
+ for (MachineRegisterInfo::reg_iterator ri = mri_->reg_begin(SrcInt.reg),
+ re = mri_->reg_end(); ri != re; ++ri) {
+ MachineOperand &O = ri.getOperand();
+ if (!O.isDef())
+ continue;
+
+ ++NumSources;
+ MachineInstr *MI = &*ri;
+ unsigned SrcReg, DstReg, SrcSubReg, DstSubReg;
+ if (!tii_->isMoveInstr(*MI, SrcReg, DstReg, SrcSubReg, DstSubReg))
+ continue;
+ if (SrcReg != DstInt.reg) {
+ OtherCopies.push_back(MI);
+ HaveConflict |= DstInt.liveAt(getInstructionIndex(MI));
+ } else {
+ IdentCopies.push_back(MI);
+ ++NumIdent;
+ }
+ }
+
+ return NumSources >= 5 && (((float)NumIdent) / NumSources) > 0.20F;
+}
+
+void LiveIntervals::performEarlyCoalescing() {
+ if (!EarlyCoalescing)
+ return;
+
+ /// Perform early coalescing: eliminate copies which feed into phi joins
+ /// and whose sources are defined by the phi joins.
+ for (unsigned i = 0, e = phiJoinCopies.size(); i != e; ++i) {
+ MachineInstr *Join = phiJoinCopies[i];
+ if (CoalescingLimit != -1 && (int)numCoalescing == CoalescingLimit)
+ break;
+
+ unsigned PHISrc, PHIDst, SrcSubReg, DstSubReg;
+ bool isMove= tii_->isMoveInstr(*Join, PHISrc, PHIDst, SrcSubReg, DstSubReg);
+#ifndef NDEBUG
+ assert(isMove && "PHI join instruction must be a move!");
+#else
+ isMove = isMove;
+#endif
+
+ LiveInterval &DstInt = getInterval(PHIDst);
+ LiveInterval &SrcInt = getInterval(PHISrc);
+ SmallVector IdentCopies;
+ SmallVector OtherCopies;
+ bool HaveConflict;
+ if (!isProfitableToCoalesce(DstInt, SrcInt, IdentCopies, OtherCopies,
+ HaveConflict))
+ continue;
+
+ DEBUG(errs() << "PHI Join: " << *Join);
+ assert(DstInt.containsOneValue() && "PHI join should have just one val#!");
+ VNInfo *VNI = DstInt.getValNumInfo(0);
+ VNInfo *NewVNI = HaveConflict
+ ? 0 : SrcInt.getNextValue(VNI->def, 0, false, VNInfoAllocator);
+ // Now let's eliminate all the would-be identity copies.
+ for (unsigned i = 0, e = IdentCopies.size(); i != e; ++i) {
+ MachineInstr *PHICopy = IdentCopies[i];
+ DEBUG(errs() << "Coalescing: " << *PHICopy);
+
+ MachineBasicBlock *PHIMBB = PHICopy->getParent();
+ MachineInstrIndex MIIndex = getInstructionIndex(PHICopy);
+ MachineInstrIndex DefIndex = getDefIndex(MIIndex);
+ LiveRange *SLR = SrcInt.getLiveRangeContaining(DefIndex);
+ MachineInstrIndex StartIndex = HaveConflict
+ ? SLR->start : getMBBStartIdx(PHIMBB);
+ MachineInstrIndex EndIndex = SLR->end;
+
+ // Delete val# defined by the now identity copy and add the range from
+ // beginning of the mbb to the end of the range.
+ SrcInt.removeValNo(SLR->valno);
+ if (HaveConflict) {
+ DEBUG(errs() << " added range [" << StartIndex << ','
+ << EndIndex << "] to reg" << DstInt.reg << '\n');
+ DstInt.addRange(LiveRange(StartIndex, EndIndex, VNI));
+ // FIXME: Update uses of src to dst in this range?
+ } else {
+ DEBUG(errs() << " added range [" << StartIndex << ','
+ << SLR->start << "] to reg" << SrcInt.reg << '\n');
+ SrcInt.addRange(LiveRange(StartIndex, EndIndex, NewVNI));
+ if (PHICopy->killsRegister(PHIDst))
+ EndIndex = DefIndex;
+ DstInt.removeRange(StartIndex, EndIndex);
+ }
+ RemoveMachineInstrFromMaps(PHICopy);
+ PHICopy->eraseFromParent();
+ }
+ if (HaveConflict) {
+ // First unset the kill.
+ for (unsigned i = 0, e = Join->getNumOperands(); i != e; ++i) {
+ MachineOperand &O = Join->getOperand(i);
+ if (!O.isReg() || O.getReg() != PHISrc)
+ continue;
+ if (O.isKill())
+ O.setIsKill(false);
+ }
+ MachineInstrIndex MIIndex = getInstructionIndex(Join);
+ MachineInstrIndex UseIndex = getUseIndex(MIIndex);
+ MachineInstrIndex DefIndex = getDefIndex(MIIndex);
+ LiveRange *SLR = SrcInt.getLiveRangeContaining(UseIndex);
+ LiveRange *DLR = DstInt.getLiveRangeContaining(DefIndex);
+ SrcInt.addRange(LiveRange(DLR->start, DLR->end, SLR->valno));
+ } else {
+ SrcInt.MergeValueInAsValue(DstInt, VNI, NewVNI);
+
+ // Change all references of phi source to destination.
+ for (MachineRegisterInfo::reg_iterator ri = mri_->reg_begin(PHIDst),
+ re = mri_->reg_end(); ri != re; ) {
+ MachineOperand &O = ri.getOperand();
+ ++ri;
+ O.setReg(PHISrc);
+ }
+ removeInterval(DstInt.reg);
+
+ RemoveMachineInstrFromMaps(Join);
+ Join->eraseFromParent();
+ }
+
+ ++numCoalescing;
+ }
+}
+
/// computeIntervals - computes the live intervals for virtual
/// registers. for some ordering of the machine instructions [1,N] a
/// live interval is an interval [i, j) where 1 <= i <= j < N for
@@ -2230,9 +2372,7 @@
return NewLIs;
}
- bool TrySplit = SplitAtBB && !intervalIsInOneMBB(li);
- if (SplitLimit != -1 && (int)numSplits >= SplitLimit)
- TrySplit = false;
+ bool TrySplit = !intervalIsInOneMBB(li);
if (TrySplit)
++numSplits;
bool NeedStackSlot = false;
@@ -2251,7 +2391,7 @@
ReMatOrigDefs[VN] = ReMatDefMI;
// Original def may be modified so we have to make a copy here.
MachineInstr *Clone = mf_->CloneMachineInstr(ReMatDefMI);
- ClonedMIs.push_back(Clone);
+ CloneMIs.push_back(Clone);
ReMatDefs[VN] = Clone;
bool CanDelete = true;
From wendling at apple.com Mon Sep 14 16:36:45 2009
From: wendling at apple.com (Bill Wendling)
Date: Mon, 14 Sep 2009 14:36:45 -0700
Subject: [llvm-commits] [llvm-gcc-4.2] r81788 -
/llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C
In-Reply-To:
References: <200909142113.n8ELDnQK000590@zion.cs.uiuc.edu>
Message-ID:
On Sep 14, 2009, at 2:31 PM, Chris Lattner wrote:
> On Sep 14, 2009, at 2:13 PM, Eric Christopher wrote:
>
>> Author: echristo
>> Date: Mon Sep 14 16:13:49 2009
>> New Revision: 81788
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=81788&view=rev
>> Log:
>> Update this test, the except table is now in the data section.
>
> But that is a "bug", so we want the test to continue failing?
>
"Bug" is a bit harsh. :-) It's just not very optimal. Plastering a
"FIXME" in there with the radar number would
be fine, perhaps?
-bw
From echristo at apple.com Mon Sep 14 16:39:27 2009
From: echristo at apple.com (Eric Christopher)
Date: Mon, 14 Sep 2009 14:39:27 -0700
Subject: [llvm-commits] [llvm-gcc-4.2] r81788 -
/llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C
In-Reply-To:
References: <200909142113.n8ELDnQK000590@zion.cs.uiuc.edu>
Message-ID: <0F0E8899-5FF6-4605-8F4C-492718DC94E4@apple.com>
On Sep 14, 2009, at 2:36 PM, Bill Wendling wrote:
> On Sep 14, 2009, at 2:31 PM, Chris Lattner wrote:
>
>> On Sep 14, 2009, at 2:13 PM, Eric Christopher wrote:
>>
>>> Author: echristo
>>> Date: Mon Sep 14 16:13:49 2009
>>> New Revision: 81788
>>>
>>> URL: http://llvm.org/viewvc/llvm-project?rev=81788&view=rev
>>> Log:
>>> Update this test, the except table is now in the data section.
>>
>> But that is a "bug", so we want the test to continue failing?
>>
> "Bug" is a bit harsh. :-) It's just not very optimal. Plastering a
> "FIXME" in there with the radar number
> would be fine, perhaps?
Mmm.. either way. I'm happy to revert as it's a bug by that
definition :)
-eric
From idadesub at users.sourceforge.net Mon Sep 14 16:54:15 2009
From: idadesub at users.sourceforge.net (Erick Tryzelaar)
Date: Mon, 14 Sep 2009 21:54:15 -0000
Subject: [llvm-commits] [llvm] r81799 - in /llvm/trunk/docs/tutorial:
OCamlLangImpl4.html OCamlLangImpl5.html OCamlLangImpl6.html
OCamlLangImpl7.html
Message-ID: <200909142154.n8ELsG6x006016@zion.cs.uiuc.edu>
Author: erickt
Date: Mon Sep 14 16:54:15 2009
New Revision: 81799
URL: http://llvm.org/viewvc/llvm-project?rev=81799&view=rev
Log:
Make sure to initialize the fpm in the ocaml tutorial.
Modified:
llvm/trunk/docs/tutorial/OCamlLangImpl4.html
llvm/trunk/docs/tutorial/OCamlLangImpl5.html
llvm/trunk/docs/tutorial/OCamlLangImpl6.html
llvm/trunk/docs/tutorial/OCamlLangImpl7.html
Modified: llvm/trunk/docs/tutorial/OCamlLangImpl4.html
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/tutorial/OCamlLangImpl4.html?rev=81799&r1=81798&r2=81799&view=diff
==============================================================================
--- llvm/trunk/docs/tutorial/OCamlLangImpl4.html (original)
+++ llvm/trunk/docs/tutorial/OCamlLangImpl4.html Mon Sep 14 16:54:15 2009
@@ -206,6 +206,8 @@
(* Simplify the control flow graph (deleting unreachable blocks, etc). *)
add_cfg_simplification the_fpm;
+ ignore (PassManager.initialize the_fpm);
+
(* Run the main "interpreter loop" now. *)
Toplevel.main_loop the_fpm the_execution_engine stream;
@@ -992,6 +994,8 @@
(* Simplify the control flow graph (deleting unreachable blocks, etc). *)
add_cfg_simplification the_fpm;
+ ignore (PassManager.initialize the_fpm);
+
(* Run the main "interpreter loop" now. *)
Toplevel.main_loop the_fpm the_execution_engine stream;
Modified: llvm/trunk/docs/tutorial/OCamlLangImpl5.html
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/tutorial/OCamlLangImpl5.html?rev=81799&r1=81798&r2=81799&view=diff
==============================================================================
--- llvm/trunk/docs/tutorial/OCamlLangImpl5.html (original)
+++ llvm/trunk/docs/tutorial/OCamlLangImpl5.html Mon Sep 14 16:54:15 2009
@@ -1519,6 +1519,8 @@
(* Simplify the control flow graph (deleting unreachable blocks, etc). *)
add_cfg_simplification the_fpm;
+ ignore (PassManager.initialize the_fpm);
+
(* Run the main "interpreter loop" now. *)
Toplevel.main_loop the_fpm the_execution_engine stream;
Modified: llvm/trunk/docs/tutorial/OCamlLangImpl6.html
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/tutorial/OCamlLangImpl6.html?rev=81799&r1=81798&r2=81799&view=diff
==============================================================================
--- llvm/trunk/docs/tutorial/OCamlLangImpl6.html (original)
+++ llvm/trunk/docs/tutorial/OCamlLangImpl6.html Mon Sep 14 16:54:15 2009
@@ -1518,6 +1518,8 @@
(* Simplify the control flow graph (deleting unreachable blocks, etc). *)
add_cfg_simplification the_fpm;
+ ignore (PassManager.initialize the_fpm);
+
(* Run the main "interpreter loop" now. *)
Toplevel.main_loop the_fpm the_execution_engine stream;
Modified: llvm/trunk/docs/tutorial/OCamlLangImpl7.html
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/tutorial/OCamlLangImpl7.html?rev=81799&r1=81798&r2=81799&view=diff
==============================================================================
--- llvm/trunk/docs/tutorial/OCamlLangImpl7.html (original)
+++ llvm/trunk/docs/tutorial/OCamlLangImpl7.html Mon Sep 14 16:54:15 2009
@@ -1852,6 +1852,8 @@
(* Simplify the control flow graph (deleting unreachable blocks, etc). *)
add_cfg_simplification the_fpm;
+ ignore (PassManager.initialize the_fpm);
+
(* Run the main "interpreter loop" now. *)
Toplevel.main_loop the_fpm the_execution_engine stream;
From idadesub at users.sourceforge.net Mon Sep 14 16:54:32 2009
From: idadesub at users.sourceforge.net (Erick Tryzelaar)
Date: Mon, 14 Sep 2009 21:54:32 -0000
Subject: [llvm-commits] [llvm] r81800 - in /llvm/trunk:
bindings/ocaml/executionengine/executionengine_ocaml.c
bindings/ocaml/executionengine/llvm_executionengine.ml
bindings/ocaml/executionengine/llvm_executionengine.mli
docs/tutorial/OCamlLangImpl4.html docs/tutorial/OCamlLangImpl5.html
docs/tutorial/OCamlLangImpl6.html docs/tutorial/OCamlLangImpl7.html
Message-ID: <200909142154.n8ELsWWG006068@zion.cs.uiuc.edu>
Author: erickt
Date: Mon Sep 14 16:54:32 2009
New Revision: 81800
URL: http://llvm.org/viewvc/llvm-project?rev=81800&view=rev
Log:
Expose initializing the native target for the execution engine.
Modified:
llvm/trunk/bindings/ocaml/executionengine/executionengine_ocaml.c
llvm/trunk/bindings/ocaml/executionengine/llvm_executionengine.ml
llvm/trunk/bindings/ocaml/executionengine/llvm_executionengine.mli
llvm/trunk/docs/tutorial/OCamlLangImpl4.html
llvm/trunk/docs/tutorial/OCamlLangImpl5.html
llvm/trunk/docs/tutorial/OCamlLangImpl6.html
llvm/trunk/docs/tutorial/OCamlLangImpl7.html
Modified: llvm/trunk/bindings/ocaml/executionengine/executionengine_ocaml.c
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/bindings/ocaml/executionengine/executionengine_ocaml.c?rev=81800&r1=81799&r2=81800&view=diff
==============================================================================
--- llvm/trunk/bindings/ocaml/executionengine/executionengine_ocaml.c (original)
+++ llvm/trunk/bindings/ocaml/executionengine/executionengine_ocaml.c Mon Sep 14 16:54:32 2009
@@ -24,11 +24,15 @@
#include
#include
-/* Force the LLVM interpreter, JIT, and native target to be linked in. */
+/* Force the LLVM interpreter and JIT to be linked in. */
void llvm_initialize(void) {
LLVMLinkInInterpreter();
LLVMLinkInJIT();
- LLVMInitializeNativeTarget();
+}
+
+/* unit -> bool */
+CAMLprim value llvm_initialize_native_target(value Unit) {
+ return Val_bool(LLVMInitializeNativeTarget());
}
/* Can't use the recommended caml_named_value mechanism for backwards
Modified: llvm/trunk/bindings/ocaml/executionengine/llvm_executionengine.ml
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/bindings/ocaml/executionengine/llvm_executionengine.ml?rev=81800&r1=81799&r2=81800&view=diff
==============================================================================
--- llvm/trunk/bindings/ocaml/executionengine/llvm_executionengine.ml (original)
+++ llvm/trunk/bindings/ocaml/executionengine/llvm_executionengine.ml Mon Sep 14 16:54:32 2009
@@ -109,3 +109,6 @@
*)
end
+
+external initialize_native_target : unit -> bool
+ = "llvm_initialize_native_target"
Modified: llvm/trunk/bindings/ocaml/executionengine/llvm_executionengine.mli
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/bindings/ocaml/executionengine/llvm_executionengine.mli?rev=81800&r1=81799&r2=81800&view=diff
==============================================================================
--- llvm/trunk/bindings/ocaml/executionengine/llvm_executionengine.mli (original)
+++ llvm/trunk/bindings/ocaml/executionengine/llvm_executionengine.mli Mon Sep 14 16:54:32 2009
@@ -161,3 +161,6 @@
[ee]. *)
val target_data: t -> Llvm_target.TargetData.t
end
+
+external initialize_native_target : unit -> bool
+ = "llvm_initialize_native_target"
Modified: llvm/trunk/docs/tutorial/OCamlLangImpl4.html
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/tutorial/OCamlLangImpl4.html?rev=81800&r1=81799&r2=81800&view=diff
==============================================================================
--- llvm/trunk/docs/tutorial/OCamlLangImpl4.html (original)
+++ llvm/trunk/docs/tutorial/OCamlLangImpl4.html Mon Sep 14 16:54:32 2009
@@ -962,6 +962,8 @@
open Llvm_scalar_opts
let main () =
+ ignore (initialize_native_target ());
+
(* Install standard binary operators.
* 1 is the lowest precedence. *)
Hashtbl.add Parser.binop_precedence '<' 10;
Modified: llvm/trunk/docs/tutorial/OCamlLangImpl5.html
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/tutorial/OCamlLangImpl5.html?rev=81800&r1=81799&r2=81800&view=diff
==============================================================================
--- llvm/trunk/docs/tutorial/OCamlLangImpl5.html (original)
+++ llvm/trunk/docs/tutorial/OCamlLangImpl5.html Mon Sep 14 16:54:32 2009
@@ -1487,6 +1487,8 @@
open Llvm_scalar_opts
let main () =
+ ignore (initialize_native_target ());
+
(* Install standard binary operators.
* 1 is the lowest precedence. *)
Hashtbl.add Parser.binop_precedence '<' 10;
Modified: llvm/trunk/docs/tutorial/OCamlLangImpl6.html
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/tutorial/OCamlLangImpl6.html?rev=81800&r1=81799&r2=81800&view=diff
==============================================================================
--- llvm/trunk/docs/tutorial/OCamlLangImpl6.html (original)
+++ llvm/trunk/docs/tutorial/OCamlLangImpl6.html Mon Sep 14 16:54:32 2009
@@ -1486,6 +1486,8 @@
open Llvm_scalar_opts
let main () =
+ ignore (initialize_native_target ());
+
(* Install standard binary operators.
* 1 is the lowest precedence. *)
Hashtbl.add Parser.binop_precedence '<' 10;
Modified: llvm/trunk/docs/tutorial/OCamlLangImpl7.html
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/tutorial/OCamlLangImpl7.html?rev=81800&r1=81799&r2=81800&view=diff
==============================================================================
--- llvm/trunk/docs/tutorial/OCamlLangImpl7.html (original)
+++ llvm/trunk/docs/tutorial/OCamlLangImpl7.html Mon Sep 14 16:54:32 2009
@@ -1816,6 +1816,8 @@
open Llvm_scalar_opts
let main () =
+ ignore (initialize_native_target ());
+
(* Install standard binary operators.
* 1 is the lowest precedence. *)
Hashtbl.add Parser.binop_precedence '=' 2;
From mrs at apple.com Mon Sep 14 16:58:46 2009
From: mrs at apple.com (Mike Stump)
Date: Mon, 14 Sep 2009 14:58:46 -0700
Subject: [llvm-commits] [llvm-gcc-4.2] r81788 -
/llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C
In-Reply-To: <0F0E8899-5FF6-4605-8F4C-492718DC94E4@apple.com>
References: <200909142113.n8ELDnQK000590@zion.cs.uiuc.edu>
<0F0E8899-5FF6-4605-8F4C-492718DC94E4@apple.com>
Message-ID: <5650EAC4-4B8F-4FEB-BE0A-AF5E0FE2A101@apple.com>
On Sep 14, 2009, at 2:39 PM, Eric Christopher wrote:
> Mmm.. either way. I'm happy to revert as it's a bug by that
> definition :)
Reversion is best I think as I suspect there are many failures in the
testsuite. The thing being tested is actually a feature of gcc.
Testing for a non-feature, would be odd. If you wanted to test
results to be cleaner, you can mark it as expected. I can dig up the
older radar number for when we switched gcc to text, if you want
(please don't ask though).
From echristo at apple.com Mon Sep 14 17:07:32 2009
From: echristo at apple.com (Eric Christopher)
Date: Mon, 14 Sep 2009 15:07:32 -0700
Subject: [llvm-commits] [llvm-gcc-4.2] r81788 -
/llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C
In-Reply-To: <5650EAC4-4B8F-4FEB-BE0A-AF5E0FE2A101@apple.com>
References: <200909142113.n8ELDnQK000590@zion.cs.uiuc.edu>
<0F0E8899-5FF6-4605-8F4C-492718DC94E4@apple.com>
<5650EAC4-4B8F-4FEB-BE0A-AF5E0FE2A101@apple.com>
Message-ID: <74AAF02F-4ECA-4522-BE03-19EB3D1EFC78@apple.com>
On Sep 14, 2009, at 2:58 PM, Mike Stump wrote:
> On Sep 14, 2009, at 2:39 PM, Eric Christopher wrote:
>> Mmm.. either way. I'm happy to revert as it's a bug by that
>> definition :)
>
> Reversion is best I think as I suspect there are many failures in
> the testsuite. The thing being tested is actually a feature of
> gcc. Testing for a non-feature, would be odd. If you wanted to
> test results to be cleaner, you can mark it as expected. I can dig
> up the older radar number for when we switched gcc to text, if you
> want (please don't ask though).
Nah. At any rate, I'm talking with Bill about it.
-eric
From kledzik at apple.com Mon Sep 14 18:26:56 2009
From: kledzik at apple.com (Nick Kledzik)
Date: Mon, 14 Sep 2009 23:26:56 -0000
Subject: [llvm-commits] [compiler-rt] r81809 - in /compiler-rt/trunk:
lib/arm/ test/Unit/
Message-ID: <200909142326.n8ENQv9B018505@zion.cs.uiuc.edu>
Author: kledzik
Date: Mon Sep 14 18:26:56 2009
New Revision: 81809
URL: http://llvm.org/viewvc/llvm-project?rev=81809&view=rev
Log:
add conversion functions and test cases for ARM
Added:
compiler-rt/trunk/lib/arm/extendsfdf2vfp.S
compiler-rt/trunk/lib/arm/fixdfsivfp.S
compiler-rt/trunk/lib/arm/fixsfsivfp.S
compiler-rt/trunk/lib/arm/fixunsdfsivfp.S
compiler-rt/trunk/lib/arm/fixunssfsivfp.S
compiler-rt/trunk/lib/arm/floatsidfvfp.S
compiler-rt/trunk/lib/arm/floatsisfvfp.S
compiler-rt/trunk/lib/arm/floatunssidfvfp.S
compiler-rt/trunk/lib/arm/floatunssisfvfp.S
compiler-rt/trunk/lib/arm/truncdfsf2vfp.S
compiler-rt/trunk/test/Unit/extebdsfdf2vfp_test.c
compiler-rt/trunk/test/Unit/fixdfsivfp_test.c
compiler-rt/trunk/test/Unit/fixsfsivfp_test.c
compiler-rt/trunk/test/Unit/fixunsdfsivfp_test.c
compiler-rt/trunk/test/Unit/fixunssfsivfp_test.c
compiler-rt/trunk/test/Unit/floatsidfvfp_test.c
compiler-rt/trunk/test/Unit/floatsisfvfp_test.c
compiler-rt/trunk/test/Unit/floatunssidfvfp_test.c
compiler-rt/trunk/test/Unit/floatunssisfvfp_test.c
compiler-rt/trunk/test/Unit/truncdfsf2vfp_test.c
Added: compiler-rt/trunk/lib/arm/extendsfdf2vfp.S
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/arm/extendsfdf2vfp.S?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/lib/arm/extendsfdf2vfp.S (added)
+++ compiler-rt/trunk/lib/arm/extendsfdf2vfp.S Mon Sep 14 18:26:56 2009
@@ -0,0 +1,23 @@
+//===-- extendsfdf2vfp.S - Implement extendsfdf2vfp -----------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+
+//
+// extern double __extendsfdf2vfp(float a);
+//
+// Converts single precision float to double precision result.
+// Uses Darwin calling convention where a single precision parameter is
+// passed in a GPR and a double precision result is returned in R0/R1 pair.
+//
+ .globl ___extendsfdf2vfp
+___extendsfdf2vfp:
+ fmsr s15, r0 // load float register from R0
+ fcvtds d7, s15 // convert single to double
+ fmrrd r0, r1, d7 // return result in r0/r1 pair
+ bx lr
Added: compiler-rt/trunk/lib/arm/fixdfsivfp.S
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/arm/fixdfsivfp.S?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/lib/arm/fixdfsivfp.S (added)
+++ compiler-rt/trunk/lib/arm/fixdfsivfp.S Mon Sep 14 18:26:56 2009
@@ -0,0 +1,23 @@
+//===-- fixdfsivfp.S - Implement fixdfsivfp -----------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+
+//
+// extern int __fixdfsivfp(double a);
+//
+// Converts double precision float to a 32-bit int rounding towards zero.
+// Uses Darwin calling convention where a double precision parameter is
+// passed in GPR register pair.
+//
+ .globl ___fixdfsivfp
+___fixdfsivfp:
+ fmdrr d7, r0, r1 // load double register from R0/R1
+ ftosizd s15, d7 // convert double to 32-bit int into s15
+ fmrs r0, s15 // move s15 to result register
+ bx lr
Added: compiler-rt/trunk/lib/arm/fixsfsivfp.S
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/arm/fixsfsivfp.S?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/lib/arm/fixsfsivfp.S (added)
+++ compiler-rt/trunk/lib/arm/fixsfsivfp.S Mon Sep 14 18:26:56 2009
@@ -0,0 +1,23 @@
+//===-- fixsfsivfp.S - Implement fixsfsivfp -----------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+
+//
+// extern int __fixsfsivfp(float a);
+//
+// Converts single precision float to a 32-bit int rounding towards zero.
+// Uses Darwin calling convention where a single precision parameter is
+// passed in a GPR..
+//
+ .globl ___fixsfsivfp
+___fixsfsivfp:
+ fmsr s15, r0 // load float register from R0
+ ftosizs s15, s15 // convert single to 32-bit int into s15
+ fmrs r0, s15 // move s15 to result register
+ bx lr
Added: compiler-rt/trunk/lib/arm/fixunsdfsivfp.S
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/arm/fixunsdfsivfp.S?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/lib/arm/fixunsdfsivfp.S (added)
+++ compiler-rt/trunk/lib/arm/fixunsdfsivfp.S Mon Sep 14 18:26:56 2009
@@ -0,0 +1,24 @@
+//===-- fixunsdfsivfp.S - Implement fixunsdfsivfp -------------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+
+//
+// extern unsigned int __fixunsdfsivfp(double a);
+//
+// Converts double precision float to a 32-bit unsigned int rounding towards
+// zero. All negative values become zero.
+// Uses Darwin calling convention where a double precision parameter is
+// passed in GPR register pair.
+//
+ .globl ___fixunsdfsivfp
+___fixunsdfsivfp:
+ fmdrr d7, r0, r1 // load double register from R0/R1
+ ftouizd s15, d7 // convert double to 32-bit int into s15
+ fmrs r0, s15 // move s15 to result register
+ bx lr
Added: compiler-rt/trunk/lib/arm/fixunssfsivfp.S
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/arm/fixunssfsivfp.S?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/lib/arm/fixunssfsivfp.S (added)
+++ compiler-rt/trunk/lib/arm/fixunssfsivfp.S Mon Sep 14 18:26:56 2009
@@ -0,0 +1,24 @@
+//===-- fixunssfsivfp.S - Implement fixunssfsivfp -------------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+
+//
+// extern unsigned int __fixunssfsivfp(float a);
+//
+// Converts single precision float to a 32-bit unsigned int rounding towards
+// zero. All negative values become zero.
+// Uses Darwin calling convention where a single precision parameter is
+// passed in a GPR..
+//
+ .globl ___fixunssfsivfp
+___fixunssfsivfp:
+ fmsr s15, r0 // load float register from R0
+ ftouizs s15, s15 // convert single to 32-bit unsigned into s15
+ fmrs r0, s15 // move s15 to result register
+ bx lr
Added: compiler-rt/trunk/lib/arm/floatsidfvfp.S
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/arm/floatsidfvfp.S?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/lib/arm/floatsidfvfp.S (added)
+++ compiler-rt/trunk/lib/arm/floatsidfvfp.S Mon Sep 14 18:26:56 2009
@@ -0,0 +1,23 @@
+//===-- floatsidfvfp.S - Implement floatsidfvfp ---------------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+
+//
+// extern double __floatsidfvfp(int a);
+//
+// Converts a 32-bit int to a double precision float.
+// Uses Darwin calling convention where a double precision result is
+// return in GPR register pair.
+//
+ .globl ___floatsidfvfp
+___floatsidfvfp:
+ fmsr s15, r0 // move int to float register s15
+ fsitod d7, s15 // convert 32-bit int in s15 to double in d7
+ fmrrd r0, r1, d7 // move d7 to result register pair r0/r1
+ bx lr
Added: compiler-rt/trunk/lib/arm/floatsisfvfp.S
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/arm/floatsisfvfp.S?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/lib/arm/floatsisfvfp.S (added)
+++ compiler-rt/trunk/lib/arm/floatsisfvfp.S Mon Sep 14 18:26:56 2009
@@ -0,0 +1,23 @@
+//===-- floatsisfvfp.S - Implement floatsisfvfp ---------------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+
+//
+// extern float __floatsisfvfp(int a);
+//
+// Converts single precision float to a 32-bit int rounding towards zero.
+// Uses Darwin calling convention where a single precision result is
+// return in a GPR..
+//
+ .globl ___floatsisfvfp
+___floatsisfvfp:
+ fmsr s15, r0 // move int to float register s15
+ fsitos s15, s15 // convert 32-bit int in s15 to float in s15
+ fmrs r0, s15 // move s15 to result register
+ bx lr
Added: compiler-rt/trunk/lib/arm/floatunssidfvfp.S
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/arm/floatunssidfvfp.S?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/lib/arm/floatunssidfvfp.S (added)
+++ compiler-rt/trunk/lib/arm/floatunssidfvfp.S Mon Sep 14 18:26:56 2009
@@ -0,0 +1,23 @@
+//===-- floatunssidfvfp.S - Implement floatunssidfvfp ---------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+
+//
+// extern double __floatunssidfvfp(unsigned int a);
+//
+// Converts a 32-bit int to a double precision float.
+// Uses Darwin calling convention where a double precision result is
+// return in GPR register pair.
+//
+ .globl ___floatunssidfvfp
+___floatunssidfvfp:
+ fmsr s15, r0 // move int to float register s15
+ fuitod d7, s15 // convert 32-bit int in s15 to double in d7
+ fmrrd r0, r1, d7 // move d7 to result register pair r0/r1
+ bx lr
Added: compiler-rt/trunk/lib/arm/floatunssisfvfp.S
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/arm/floatunssisfvfp.S?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/lib/arm/floatunssisfvfp.S (added)
+++ compiler-rt/trunk/lib/arm/floatunssisfvfp.S Mon Sep 14 18:26:56 2009
@@ -0,0 +1,23 @@
+//===-- floatunssisfvfp.S - Implement floatunssisfvfp ---------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+
+//
+// extern float __floatunssisfvfp(unsigned int a);
+//
+// Converts single precision float to a 32-bit int rounding towards zero.
+// Uses Darwin calling convention where a single precision result is
+// return in a GPR..
+//
+ .globl ___floatunssisfvfp
+___floatunssisfvfp:
+ fmsr s15, r0 // move int to float register s15
+ fuitos s15, s15 // convert 32-bit int in s15 to float in s15
+ fmrs r0, s15 // move s15 to result register
+ bx lr
Added: compiler-rt/trunk/lib/arm/truncdfsf2vfp.S
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/arm/truncdfsf2vfp.S?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/lib/arm/truncdfsf2vfp.S (added)
+++ compiler-rt/trunk/lib/arm/truncdfsf2vfp.S Mon Sep 14 18:26:56 2009
@@ -0,0 +1,23 @@
+//===-- truncdfsf2vfp.S - Implement truncdfsf2vfp -------------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+
+//
+// extern float __truncdfsf2vfp(double a);
+//
+// Converts double precision float to signle precision result.
+// Uses Darwin calling convention where a double precision parameter is
+// passed in a R0/R1 pair and a signle precision result is returned in R0.
+//
+ .globl ___truncdfsf2vfp
+___truncdfsf2vfp:
+ fmdrr d7, r0, r1 // load double from r0/r1 pair
+ fcvtsd s15, d7 // convert double to single (trucate precision)
+ fmrs r0, s15 // return result in r0
+ bx lr
Added: compiler-rt/trunk/test/Unit/extebdsfdf2vfp_test.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/Unit/extebdsfdf2vfp_test.c?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/test/Unit/extebdsfdf2vfp_test.c (added)
+++ compiler-rt/trunk/test/Unit/extebdsfdf2vfp_test.c Mon Sep 14 18:26:56 2009
@@ -0,0 +1,46 @@
+//===-- extendsfdf2vfp_test.c - Test __extendsfdf2vfp ---------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file tests __extendsfdf2vfp for the compiler_rt library.
+//
+//===----------------------------------------------------------------------===//
+
+#include
+#include
+#include
+
+
+extern double __extendsfdf2vfp(float a);
+
+#if __arm__
+int test__extendsfdf2vfp(float a)
+{
+ double actual = __extendsfdf2vfp(a);
+ double expected = a;
+ if (actual != expected)
+ printf("error in test__extendsfdf2vfp(%f) = %f, expected %f\n",
+ a, actual, expected);
+ return actual != expected;
+}
+#endif
+
+int main()
+{
+#if __arm__
+ if (test__extendsfdf2vfp(0.0))
+ return 1;
+ if (test__extendsfdf2vfp(1.0))
+ return 1;
+ if (test__extendsfdf2vfp(-1.0))
+ return 1;
+ if (test__extendsfdf2vfp(3.1415926535))
+ return 1;
+#endif
+ return 0;
+}
Added: compiler-rt/trunk/test/Unit/fixdfsivfp_test.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/Unit/fixdfsivfp_test.c?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/test/Unit/fixdfsivfp_test.c (added)
+++ compiler-rt/trunk/test/Unit/fixdfsivfp_test.c Mon Sep 14 18:26:56 2009
@@ -0,0 +1,48 @@
+//===-- fixdfsivfp_test.c - Test __fixdfsivfp -----------------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file tests __fixdfsivfp for the compiler_rt library.
+//
+//===----------------------------------------------------------------------===//
+
+#include
+#include
+#include
+
+
+extern int __fixdfsivfp(double a);
+
+#if __arm__
+int test__fixdfsivfp(double a)
+{
+ int actual = __fixdfsivfp(a);
+ int expected = a;
+ if (actual != expected)
+ printf("error in test__fixdfsivfp(%f) = %d, expected %d\n",
+ a, actual, expected);
+ return actual != expected;
+}
+#endif
+
+int main()
+{
+#if __arm__
+ if (test__fixdfsivfp(0.0))
+ return 1;
+ if (test__fixdfsivfp(1.0))
+ return 1;
+ if (test__fixdfsivfp(-1.0))
+ return 1;
+ if (test__fixdfsivfp(2147483647))
+ return 1;
+ if (test__fixdfsivfp(-2147483648.0))
+ return 1;
+#endif
+ return 0;
+}
Added: compiler-rt/trunk/test/Unit/fixsfsivfp_test.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/Unit/fixsfsivfp_test.c?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/test/Unit/fixsfsivfp_test.c (added)
+++ compiler-rt/trunk/test/Unit/fixsfsivfp_test.c Mon Sep 14 18:26:56 2009
@@ -0,0 +1,50 @@
+//===-- fixsfsivfp_test.c - Test __fixsfsivfp -----------------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file tests __fixsfsivfp for the compiler_rt library.
+//
+//===----------------------------------------------------------------------===//
+
+#include
+#include
+#include
+
+
+extern int __fixsfsivfp(float a);
+
+#if __arm__
+int test__fixsfsivfp(float a)
+{
+ int actual = __fixsfsivfp(a);
+ int expected = a;
+ if (actual != expected)
+ printf("error in test__fixsfsivfp(%f) = %u, expected %u\n",
+ a, actual, expected);
+ return actual != expected;
+}
+#endif
+
+int main()
+{
+#if __arm__
+ if (test__fixsfsivfp(0.0))
+ return 1;
+ if (test__fixsfsivfp(1.0))
+ return 1;
+ if (test__fixsfsivfp(-1.0))
+ return 1;
+ if (test__fixsfsivfp(2147483647.0))
+ return 1;
+ if (test__fixsfsivfp(-2147483648.0))
+ return 1;
+ if (test__fixsfsivfp(65536.0))
+ return 1;
+#endif
+ return 0;
+}
Added: compiler-rt/trunk/test/Unit/fixunsdfsivfp_test.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/Unit/fixunsdfsivfp_test.c?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/test/Unit/fixunsdfsivfp_test.c (added)
+++ compiler-rt/trunk/test/Unit/fixunsdfsivfp_test.c Mon Sep 14 18:26:56 2009
@@ -0,0 +1,48 @@
+//===-- fixunsdfsivfp_test.c - Test __fixunsdfsivfp -----------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file tests __fixunsdfsivfp for the compiler_rt library.
+//
+//===----------------------------------------------------------------------===//
+
+#include
+#include
+#include
+
+
+extern unsigned int __fixunsdfsivfp(double a);
+
+#if __arm__
+int test__fixunsdfsivfp(double a)
+{
+ unsigned int actual = __fixunsdfsivfp(a);
+ unsigned int expected = a;
+ if (actual != expected)
+ printf("error in test__fixunsdfsivfp(%f) = %u, expected %u\n",
+ a, actual, expected);
+ return actual != expected;
+}
+#endif
+
+int main()
+{
+#if __arm__
+ if (test__fixunsdfsivfp(0.0))
+ return 1;
+ if (test__fixunsdfsivfp(1.0))
+ return 1;
+ if (test__fixunsdfsivfp(-1.0))
+ return 1;
+ if (test__fixunsdfsivfp(4294967295.0))
+ return 1;
+ if (test__fixunsdfsivfp(65536.0))
+ return 1;
+#endif
+ return 0;
+}
Added: compiler-rt/trunk/test/Unit/fixunssfsivfp_test.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/Unit/fixunssfsivfp_test.c?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/test/Unit/fixunssfsivfp_test.c (added)
+++ compiler-rt/trunk/test/Unit/fixunssfsivfp_test.c Mon Sep 14 18:26:56 2009
@@ -0,0 +1,48 @@
+//===-- fixunssfsivfp_test.c - Test __fixunssfsivfp -----------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file tests __fixunssfsivfp for the compiler_rt library.
+//
+//===----------------------------------------------------------------------===//
+
+#include
+#include
+#include
+
+
+extern unsigned int __fixunssfsivfp(float a);
+
+#if __arm__
+int test__fixunssfsivfp(float a)
+{
+ unsigned int actual = __fixunssfsivfp(a);
+ unsigned int expected = a;
+ if (actual != expected)
+ printf("error in test__fixunssfsivfp(%f) = %u, expected %u\n",
+ a, actual, expected);
+ return actual != expected;
+}
+#endif
+
+int main()
+{
+#if __arm__
+ if (test__fixunssfsivfp(0.0))
+ return 1;
+ if (test__fixunssfsivfp(1.0))
+ return 1;
+ if (test__fixunssfsivfp(-1.0))
+ return 1;
+ if (test__fixunssfsivfp(4294967295.0))
+ return 1;
+ if (test__fixunssfsivfp(65536.0))
+ return 1;
+#endif
+ return 0;
+}
Added: compiler-rt/trunk/test/Unit/floatsidfvfp_test.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/Unit/floatsidfvfp_test.c?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/test/Unit/floatsidfvfp_test.c (added)
+++ compiler-rt/trunk/test/Unit/floatsidfvfp_test.c Mon Sep 14 18:26:56 2009
@@ -0,0 +1,48 @@
+//===-- floatsidfvfp_test.c - Test __floatsidfvfp -------------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file tests __floatsidfvfp for the compiler_rt library.
+//
+//===----------------------------------------------------------------------===//
+
+#include
+#include
+#include
+
+
+extern double __floatsidfvfp(int a);
+
+#if __arm__
+int test__floatsidfvfp(int a)
+{
+ double actual = __floatsidfvfp(a);
+ double expected = a;
+ if (actual != expected)
+ printf("error in test__ floatsidfvfp(%d) = %f, expected %f\n",
+ a, actual, expected);
+ return actual != expected;
+}
+#endif
+
+int main()
+{
+#if __arm__
+ if (test__floatsidfvfp(0))
+ return 1;
+ if (test__floatsidfvfp(1))
+ return 1;
+ if (test__floatsidfvfp(-1))
+ return 1;
+ if (test__floatsidfvfp(0x7FFFFFFF))
+ return 1;
+ if (test__floatsidfvfp(0x80000000))
+ return 1;
+#endif
+ return 0;
+}
Added: compiler-rt/trunk/test/Unit/floatsisfvfp_test.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/Unit/floatsisfvfp_test.c?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/test/Unit/floatsisfvfp_test.c (added)
+++ compiler-rt/trunk/test/Unit/floatsisfvfp_test.c Mon Sep 14 18:26:56 2009
@@ -0,0 +1,48 @@
+//===-- floatsisfvfp_test.c - Test __floatsisfvfp -------------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file tests __floatsisfvfp for the compiler_rt library.
+//
+//===----------------------------------------------------------------------===//
+
+#include
+#include
+#include
+
+
+extern float __floatsisfvfp(int a);
+
+#if __arm__
+int test__floatsisfvfp(int a)
+{
+ float actual = __floatsisfvfp(a);
+ float expected = a;
+ if (actual != expected)
+ printf("error in test__floatsisfvfp(%d) = %f, expected %f\n",
+ a, actual, expected);
+ return actual != expected;
+}
+#endif
+
+int main()
+{
+#if __arm__
+ if (test__floatsisfvfp(0))
+ return 1;
+ if (test__floatsisfvfp(1))
+ return 1;
+ if (test__floatsisfvfp(-1))
+ return 1;
+ if (test__floatsisfvfp(0x7FFFFFFF))
+ return 1;
+ if (test__floatsisfvfp(0x80000000))
+ return 1;
+#endif
+ return 0;
+}
Added: compiler-rt/trunk/test/Unit/floatunssidfvfp_test.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/Unit/floatunssidfvfp_test.c?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/test/Unit/floatunssidfvfp_test.c (added)
+++ compiler-rt/trunk/test/Unit/floatunssidfvfp_test.c Mon Sep 14 18:26:56 2009
@@ -0,0 +1,48 @@
+//===-- floatunssidfvfp_test.c - Test __floatunssidfvfp -------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file tests __floatunssidfvfp for the compiler_rt library.
+//
+//===----------------------------------------------------------------------===//
+
+#include
+#include
+#include
+
+
+extern double __floatunssidfvfp(unsigned int a);
+
+#if __arm__
+int test__floatunssidfvfp(unsigned int a)
+{
+ double actual = __floatunssidfvfp(a);
+ double expected = a;
+ if (actual != expected)
+ printf("error in test__floatunssidfvfp(%u) = %f, expected %f\n",
+ a, actual, expected);
+ return actual != expected;
+}
+#endif
+
+int main()
+{
+#if __arm__
+ if (test__floatunssidfvfp(0))
+ return 1;
+ if (test__floatunssidfvfp(1))
+ return 1;
+ if (test__floatunssidfvfp(0x7FFFFFFF))
+ return 1;
+ if (test__floatunssidfvfp(0x80000000))
+ return 1;
+ if (test__floatunssidfvfp(0xFFFFFFFF))
+ return 1;
+#endif
+ return 0;
+}
Added: compiler-rt/trunk/test/Unit/floatunssisfvfp_test.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/Unit/floatunssisfvfp_test.c?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/test/Unit/floatunssisfvfp_test.c (added)
+++ compiler-rt/trunk/test/Unit/floatunssisfvfp_test.c Mon Sep 14 18:26:56 2009
@@ -0,0 +1,48 @@
+//===-- floatunssisfvfp_test.c - Test __floatunssisfvfp -------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file tests __floatunssisfvfp for the compiler_rt library.
+//
+//===----------------------------------------------------------------------===//
+
+#include
+#include
+#include
+
+
+extern float __floatunssisfvfp(unsigned int a);
+
+#if __arm__
+int test__floatunssisfvfp(unsigned int a)
+{
+ float actual = __floatunssisfvfp(a);
+ float expected = a;
+ if (actual != expected)
+ printf("error in test__floatunssisfvfp(%u) = %f, expected %f\n",
+ a, actual, expected);
+ return actual != expected;
+}
+#endif
+
+int main()
+{
+#if __arm__
+ if (test__floatunssisfvfp(0))
+ return 1;
+ if (test__floatunssisfvfp(1))
+ return 1;
+ if (test__floatunssisfvfp(0x7FFFFFFF))
+ return 1;
+ if (test__floatunssisfvfp(0x80000000))
+ return 1;
+ if (test__floatunssisfvfp(0xFFFFFFFF))
+ return 1;
+#endif
+ return 0;
+}
Added: compiler-rt/trunk/test/Unit/truncdfsf2vfp_test.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/Unit/truncdfsf2vfp_test.c?rev=81809&view=auto
==============================================================================
--- compiler-rt/trunk/test/Unit/truncdfsf2vfp_test.c (added)
+++ compiler-rt/trunk/test/Unit/truncdfsf2vfp_test.c Mon Sep 14 18:26:56 2009
@@ -0,0 +1,48 @@
+//===-- truncdfsf2vfp_test.c - Test __truncdfsf2vfp -----------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file tests __truncdfsf2vfp for the compiler_rt library.
+//
+//===----------------------------------------------------------------------===//
+
+#include
+#include
+#include
+
+
+extern float __truncdfsf2vfp(double a);
+
+#if __arm__
+int test__truncdfsf2vfp(double a)
+{
+ float actual = __truncdfsf2vfp(a);
+ float expected = a;
+ if (actual != expected)
+ printf("error in test__truncdfsf2vfp(%f) = %f, expected %f\n",
+ a, actual, expected);
+ return actual != expected;
+}
+#endif
+
+int main()
+{
+#if __arm__
+ if (test__truncdfsf2vfp(0.0))
+ return 1;
+ if (test__truncdfsf2vfp(1.0))
+ return 1;
+ if (test__truncdfsf2vfp(-1.0))
+ return 1;
+ if (test__truncdfsf2vfp(3.1415926535))
+ return 1;
+ if (test__truncdfsf2vfp(123.456))
+ return 1;
+#endif
+ return 0;
+}
From gohman at apple.com Mon Sep 14 18:39:10 2009
From: gohman at apple.com (Dan Gohman)
Date: Mon, 14 Sep 2009 23:39:10 -0000
Subject: [llvm-commits] [llvm] r81810 - in /llvm/trunk:
lib/Transforms/Scalar/MemCpyOptimizer.cpp
test/Transforms/MemCpyOpt/align.ll
Message-ID: <200909142339.n8ENdBg2020112@zion.cs.uiuc.edu>
Author: djg
Date: Mon Sep 14 18:39:10 2009
New Revision: 81810
URL: http://llvm.org/viewvc/llvm-project?rev=81810&view=rev
Log:
When extending a memset range past the front, set the alignment of the
memset region to the alignment of the new start address.
Added:
llvm/trunk/test/Transforms/MemCpyOpt/align.ll
Modified:
llvm/trunk/lib/Transforms/Scalar/MemCpyOptimizer.cpp
Modified: llvm/trunk/lib/Transforms/Scalar/MemCpyOptimizer.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/MemCpyOptimizer.cpp?rev=81810&r1=81809&r2=81810&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/MemCpyOptimizer.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/MemCpyOptimizer.cpp Mon Sep 14 18:39:10 2009
@@ -273,6 +273,7 @@
if (Start < I->Start) {
I->Start = Start;
I->StartPtr = SI->getPointerOperand();
+ I->Alignment = SI->getAlignment();
}
// Now we know that Start <= I->End and Start >= I->Start (so the startpoint
Added: llvm/trunk/test/Transforms/MemCpyOpt/align.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Transforms/MemCpyOpt/align.ll?rev=81810&view=auto
==============================================================================
--- llvm/trunk/test/Transforms/MemCpyOpt/align.ll (added)
+++ llvm/trunk/test/Transforms/MemCpyOpt/align.ll Mon Sep 14 18:39:10 2009
@@ -0,0 +1,18 @@
+; RUN: opt < %s -S -memcpyopt | FileCheck %s
+
+; The resulting memset is only 4-byte aligned, despite containing
+; a 16-byte alignmed store in the middle.
+
+; CHECK: call void @llvm.memset.i64(i8* %a01, i8 0, i64 16, i32 4)
+
+define void @foo(i32* %p) {
+ %a0 = getelementptr i32* %p, i64 0
+ store i32 0, i32* %a0, align 4
+ %a1 = getelementptr i32* %p, i64 1
+ store i32 0, i32* %a1, align 16
+ %a2 = getelementptr i32* %p, i64 2
+ store i32 0, i32* %a2, align 4
+ %a3 = getelementptr i32* %p, i64 3
+ store i32 0, i32* %a3, align 4
+ ret void
+}
From clattner at apple.com Mon Sep 14 18:40:14 2009
From: clattner at apple.com (Chris Lattner)
Date: Mon, 14 Sep 2009 16:40:14 -0700
Subject: [llvm-commits] [llvm-gcc-4.2] r81788 -
/llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C
In-Reply-To: <5650EAC4-4B8F-4FEB-BE0A-AF5E0FE2A101@apple.com>
References: <200909142113.n8ELDnQK000590@zion.cs.uiuc.edu>
<0F0E8899-5FF6-4605-8F4C-492718DC94E4@apple.com>
<5650EAC4-4B8F-4FEB-BE0A-AF5E0FE2A101@apple.com>
Message-ID: <9B99C10F-203C-4DB4-AFEF-47215F63F31D@apple.com>
On Sep 14, 2009, at 2:58 PM, Mike Stump wrote:
> On Sep 14, 2009, at 2:39 PM, Eric Christopher wrote:
>> Mmm.. either way. I'm happy to revert as it's a bug by that
>> definition :)
>
> Reversion is best I think as I suspect there are many failures in the
> testsuite.
Yes, I agree with mike, reverting is best IMO. If we were going from
1 failure to 0, I'd be ok with this, if we're going from 1000 failures
to 999, it is best to leave it failing.
Adding a comment to the testcase with a radar number pointing out the
llvm issue would be a good idea though so that future people analyzing
the issue won't redo the work you've done.
-Chris
> The thing being tested is actually a feature of gcc.
> Testing for a non-feature, would be odd. If you wanted to test
> results to be cleaner, you can mark it as expected. I can dig up the
> older radar number for when we switched gcc to text, if you want
> (please don't ask though).
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From natebegeman at mac.com Mon Sep 14 19:13:12 2009
From: natebegeman at mac.com (Nate Begeman)
Date: Tue, 15 Sep 2009 00:13:12 -0000
Subject: [llvm-commits] [llvm] r81813 - in /llvm/trunk:
include/llvm/CodeGen/SelectionDAG.h
include/llvm/CodeGen/SelectionDAGNodes.h
lib/CodeGen/SelectionDAG/SelectionDAG.cpp
lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp
Message-ID: <200909150013.n8F0DCbX024473@zion.cs.uiuc.edu>
Author: sampo
Date: Mon Sep 14 19:13:12 2009
New Revision: 81813
URL: http://llvm.org/viewvc/llvm-project?rev=81813&view=rev
Log:
Add an "original alignment" field to load and store nodes. This enables the
DAG Combiner to disambiguate chains for loads and stores of types which are
broken up by the Legalizer into smaller pieces.
Modified:
llvm/trunk/include/llvm/CodeGen/SelectionDAG.h
llvm/trunk/include/llvm/CodeGen/SelectionDAGNodes.h
llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp
Modified: llvm/trunk/include/llvm/CodeGen/SelectionDAG.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/CodeGen/SelectionDAG.h?rev=81813&r1=81812&r2=81813&view=diff
==============================================================================
--- llvm/trunk/include/llvm/CodeGen/SelectionDAG.h (original)
+++ llvm/trunk/include/llvm/CodeGen/SelectionDAG.h Mon Sep 14 19:13:12 2009
@@ -544,7 +544,7 @@
///
SDValue getLoad(EVT VT, DebugLoc dl, SDValue Chain, SDValue Ptr,
const Value *SV, int SVOffset, bool isVolatile=false,
- unsigned Alignment=0);
+ unsigned Alignment=0, unsigned OrigAlignment=0);
SDValue getExtLoad(ISD::LoadExtType ExtType, DebugLoc dl, EVT VT,
SDValue Chain, SDValue Ptr, const Value *SV,
int SVOffset, EVT EVT, bool isVolatile=false,
@@ -552,16 +552,16 @@
SDValue getIndexedLoad(SDValue OrigLoad, DebugLoc dl, SDValue Base,
SDValue Offset, ISD::MemIndexedMode AM);
SDValue getLoad(ISD::MemIndexedMode AM, DebugLoc dl, ISD::LoadExtType ExtType,
- EVT VT, SDValue Chain,
- SDValue Ptr, SDValue Offset,
- const Value *SV, int SVOffset, EVT EVT,
- bool isVolatile=false, unsigned Alignment=0);
+ EVT VT, SDValue Chain, SDValue Ptr, SDValue Offset,
+ const Value *SV, int SVOffset, EVT EVT,
+ bool isVolatile=false, unsigned Alignment=0,
+ unsigned OrigAlignment=0);
/// getStore - Helper function to build ISD::STORE nodes.
///
SDValue getStore(SDValue Chain, DebugLoc dl, SDValue Val, SDValue Ptr,
const Value *SV, int SVOffset, bool isVolatile=false,
- unsigned Alignment=0);
+ unsigned Alignment=0, unsigned OrigAlignment=0);
SDValue getTruncStore(SDValue Chain, DebugLoc dl, SDValue Val, SDValue Ptr,
const Value *SV, int SVOffset, EVT TVT,
bool isVolatile=false, unsigned Alignment=0);
Modified: llvm/trunk/include/llvm/CodeGen/SelectionDAGNodes.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/CodeGen/SelectionDAGNodes.h?rev=81813&r1=81812&r2=81813&view=diff
==============================================================================
--- llvm/trunk/include/llvm/CodeGen/SelectionDAGNodes.h (original)
+++ llvm/trunk/include/llvm/CodeGen/SelectionDAGNodes.h Mon Sep 14 19:13:12 2009
@@ -1519,17 +1519,22 @@
//! SVOffset - Memory location offset. Note that base is defined in MemSDNode
int SVOffset;
+ //! OrigAlign - The original alignment of this MemSDNode in the case where
+ // this node was created by legalize from a MemSDNode with known alignment.
+ unsigned OrigAlign;
+
public:
MemSDNode(unsigned Opc, DebugLoc dl, SDVTList VTs, EVT MemoryVT,
const Value *srcValue, int SVOff,
- unsigned alignment, bool isvolatile);
+ unsigned alignment, bool isvolatile, unsigned oalign);
MemSDNode(unsigned Opc, DebugLoc dl, SDVTList VTs, const SDValue *Ops,
unsigned NumOps, EVT MemoryVT, const Value *srcValue, int SVOff,
- unsigned alignment, bool isvolatile);
+ unsigned alignment, bool isvolatile, unsigned oalign);
/// Returns alignment and volatility of the memory access
unsigned getAlignment() const { return (1u << (SubclassData >> 6)) >> 1; }
+ unsigned getOriginalAlignment() const { return OrigAlign; }
bool isVolatile() const { return (SubclassData >> 5) & 1; }
/// getRawSubclassData - Return the SubclassData value, which contains an
@@ -1600,14 +1605,14 @@
SDValue Cmp, SDValue Swp, const Value* SrcVal,
unsigned Align=0)
: MemSDNode(Opc, dl, VTL, MemVT, SrcVal, /*SVOffset=*/0,
- Align, /*isVolatile=*/true) {
+ Align, /*isVolatile=*/true, /* OrigAlign=*/0) {
InitOperands(Ops, Chain, Ptr, Cmp, Swp);
}
AtomicSDNode(unsigned Opc, DebugLoc dl, SDVTList VTL, EVT MemVT,
SDValue Chain, SDValue Ptr,
SDValue Val, const Value* SrcVal, unsigned Align=0)
: MemSDNode(Opc, dl, VTL, MemVT, SrcVal, /*SVOffset=*/0,
- Align, /*isVolatile=*/true) {
+ Align, /*isVolatile=*/true, /* OrigAlign=*/0) {
InitOperands(Ops, Chain, Ptr, Val);
}
@@ -1648,7 +1653,8 @@
const SDValue *Ops, unsigned NumOps,
EVT MemoryVT, const Value *srcValue, int SVO,
unsigned Align, bool Vol, bool ReadMem, bool WriteMem)
- : MemSDNode(Opc, dl, VTs, Ops, NumOps, MemoryVT, srcValue, SVO, Align, Vol),
+ : MemSDNode(Opc, dl, VTs, Ops, NumOps, MemoryVT, srcValue, SVO, Align, Vol,
+ /* OrigAlign=*/0),
ReadMem(ReadMem), WriteMem(WriteMem) {
}
@@ -2263,8 +2269,9 @@
public:
LSBaseSDNode(ISD::NodeType NodeTy, DebugLoc dl, SDValue *Operands,
unsigned numOperands, SDVTList VTs, ISD::MemIndexedMode AM,
- EVT VT, const Value *SV, int SVO, unsigned Align, bool Vol)
- : MemSDNode(NodeTy, dl, VTs, VT, SV, SVO, Align, Vol) {
+ EVT VT, const Value *SV, int SVO, unsigned Align, bool Vol,
+ unsigned OAlign)
+ : MemSDNode(NodeTy, dl, VTs, VT, SV, SVO, Align, Vol, OAlign) {
assert(Align != 0 && "Loads and stores should have non-zero aligment");
SubclassData |= AM << 2;
assert(getAddressingMode() == AM && "MemIndexedMode encoding error!");
@@ -2302,9 +2309,10 @@
friend class SelectionDAG;
LoadSDNode(SDValue *ChainPtrOff, DebugLoc dl, SDVTList VTs,
ISD::MemIndexedMode AM, ISD::LoadExtType ETy, EVT LVT,
- const Value *SV, int O=0, unsigned Align=0, bool Vol=false)
+ const Value *SV, int O=0, unsigned Align=0, bool Vol=false,
+ unsigned OAlign=0)
: LSBaseSDNode(ISD::LOAD, dl, ChainPtrOff, 3,
- VTs, AM, LVT, SV, O, Align, Vol) {
+ VTs, AM, LVT, SV, O, Align, Vol, OAlign) {
SubclassData |= (unsigned short)ETy;
assert(getExtensionType() == ETy && "LoadExtType encoding error!");
}
@@ -2331,9 +2339,10 @@
friend class SelectionDAG;
StoreSDNode(SDValue *ChainValuePtrOff, DebugLoc dl, SDVTList VTs,
ISD::MemIndexedMode AM, bool isTrunc, EVT SVT,
- const Value *SV, int O=0, unsigned Align=0, bool Vol=false)
+ const Value *SV, int O=0, unsigned Align=0, bool Vol=false,
+ unsigned OAlign=0)
: LSBaseSDNode(ISD::STORE, dl, ChainValuePtrOff, 4,
- VTs, AM, SVT, SV, O, Align, Vol) {
+ VTs, AM, SVT, SV, O, Align, Vol, OAlign) {
SubclassData |= (unsigned short)isTrunc;
assert(isTruncatingStore() == isTrunc && "isTrunc encoding error!");
}
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAG.cpp?rev=81813&r1=81812&r2=81813&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAG.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAG.cpp Mon Sep 14 19:13:12 2009
@@ -3646,9 +3646,12 @@
ISD::LoadExtType ExtType, EVT VT, SDValue Chain,
SDValue Ptr, SDValue Offset,
const Value *SV, int SVOffset, EVT EVT,
- bool isVolatile, unsigned Alignment) {
+ bool isVolatile, unsigned Alignment,
+ unsigned OrigAlignment) {
if (Alignment == 0) // Ensure that codegen never sees alignment 0
Alignment = getEVTAlignment(VT);
+ if (OrigAlignment == 0)
+ OrigAlignment = Alignment;
if (VT == EVT) {
ExtType = ISD::NON_EXTLOAD;
@@ -3679,12 +3682,13 @@
AddNodeIDNode(ID, ISD::LOAD, VTs, Ops, 3);
ID.AddInteger(EVT.getRawBits());
ID.AddInteger(encodeMemSDNodeFlags(ExtType, AM, isVolatile, Alignment));
+ ID.AddInteger(OrigAlignment);
void *IP = 0;
if (SDNode *E = CSEMap.FindNodeOrInsertPos(ID, IP))
return SDValue(E, 0);
SDNode *N = NodeAllocator.Allocate();
new (N) LoadSDNode(Ops, dl, VTs, AM, ExtType, EVT, SV, SVOffset,
- Alignment, isVolatile);
+ Alignment, isVolatile, OrigAlignment);
CSEMap.InsertNode(N, IP);
AllNodes.push_back(N);
return SDValue(N, 0);
@@ -3693,10 +3697,11 @@
SDValue SelectionDAG::getLoad(EVT VT, DebugLoc dl,
SDValue Chain, SDValue Ptr,
const Value *SV, int SVOffset,
- bool isVolatile, unsigned Alignment) {
+ bool isVolatile, unsigned Alignment,
+ unsigned OrigAlignment) {
SDValue Undef = getUNDEF(Ptr.getValueType());
return getLoad(ISD::UNINDEXED, dl, ISD::NON_EXTLOAD, VT, Chain, Ptr, Undef,
- SV, SVOffset, VT, isVolatile, Alignment);
+ SV, SVOffset, VT, isVolatile, Alignment, OrigAlignment);
}
SDValue SelectionDAG::getExtLoad(ISD::LoadExtType ExtType, DebugLoc dl, EVT VT,
@@ -3723,11 +3728,14 @@
SDValue SelectionDAG::getStore(SDValue Chain, DebugLoc dl, SDValue Val,
SDValue Ptr, const Value *SV, int SVOffset,
- bool isVolatile, unsigned Alignment) {
+ bool isVolatile, unsigned Alignment,
+ unsigned OrigAlignment) {
EVT VT = Val.getValueType();
if (Alignment == 0) // Ensure that codegen never sees alignment 0
Alignment = getEVTAlignment(VT);
+ if (OrigAlignment == 0)
+ OrigAlignment = Alignment;
SDVTList VTs = getVTList(MVT::Other);
SDValue Undef = getUNDEF(Ptr.getValueType());
@@ -3737,12 +3745,13 @@
ID.AddInteger(VT.getRawBits());
ID.AddInteger(encodeMemSDNodeFlags(false, ISD::UNINDEXED,
isVolatile, Alignment));
+ ID.AddInteger(OrigAlignment);
void *IP = 0;
if (SDNode *E = CSEMap.FindNodeOrInsertPos(ID, IP))
return SDValue(E, 0);
SDNode *N = NodeAllocator.Allocate();
new (N) StoreSDNode(Ops, dl, VTs, ISD::UNINDEXED, false,
- VT, SV, SVOffset, Alignment, isVolatile);
+ VT, SV, SVOffset, Alignment, isVolatile, OrigAlignment);
CSEMap.InsertNode(N, IP);
AllNodes.push_back(N);
return SDValue(N, 0);
@@ -4968,9 +4977,10 @@
}
MemSDNode::MemSDNode(unsigned Opc, DebugLoc dl, SDVTList VTs, EVT memvt,
- const Value *srcValue, int SVO,
- unsigned alignment, bool vol)
- : SDNode(Opc, dl, VTs), MemoryVT(memvt), SrcValue(srcValue), SVOffset(SVO) {
+ const Value *srcValue, int SVO, unsigned alignment,
+ bool vol, unsigned origAlign)
+ : SDNode(Opc, dl, VTs), MemoryVT(memvt), SrcValue(srcValue), SVOffset(SVO),
+ OrigAlign(origAlign) {
SubclassData = encodeMemSDNodeFlags(0, ISD::UNINDEXED, vol, alignment);
assert(isPowerOf2_32(alignment) && "Alignment is not a power of 2!");
assert(getAlignment() == alignment && "Alignment representation error!");
@@ -4978,11 +4988,11 @@
}
MemSDNode::MemSDNode(unsigned Opc, DebugLoc dl, SDVTList VTs,
- const SDValue *Ops,
- unsigned NumOps, EVT memvt, const Value *srcValue,
- int SVO, unsigned alignment, bool vol)
+ const SDValue *Ops, unsigned NumOps, EVT memvt,
+ const Value *srcValue, int SVO, unsigned alignment,
+ bool vol, unsigned origAlign)
: SDNode(Opc, dl, VTs, Ops, NumOps),
- MemoryVT(memvt), SrcValue(srcValue), SVOffset(SVO) {
+ MemoryVT(memvt), SrcValue(srcValue), SVOffset(SVO), OrigAlign(origAlign) {
SubclassData = encodeMemSDNodeFlags(0, ISD::UNINDEXED, vol, alignment);
assert(isPowerOf2_32(alignment) && "Alignment is not a power of 2!");
assert(getAlignment() == alignment && "Alignment representation error!");
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp?rev=81813&r1=81812&r2=81813&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp Mon Sep 14 19:13:12 2009
@@ -2812,11 +2812,10 @@
EVT PtrVT = Ptr.getValueType();
for (unsigned i = 0; i != NumValues; ++i) {
SDValue L = DAG.getLoad(ValueVTs[i], getCurDebugLoc(), Root,
- DAG.getNode(ISD::ADD, getCurDebugLoc(),
- PtrVT, Ptr,
- DAG.getConstant(Offsets[i], PtrVT)),
- SV, Offsets[i],
- isVolatile, Alignment);
+ DAG.getNode(ISD::ADD, getCurDebugLoc(),
+ PtrVT, Ptr,
+ DAG.getConstant(Offsets[i], PtrVT)),
+ SV, Offsets[i], isVolatile, Alignment, Alignment);
Values[i] = L;
Chains[i] = L.getValue(1);
}
@@ -2866,7 +2865,7 @@
PtrVT, Ptr,
DAG.getConstant(Offsets[i], PtrVT)),
PtrV, Offsets[i],
- isVolatile, Alignment);
+ isVolatile, Alignment, Alignment);
DAG.setRoot(DAG.getNode(ISD::TokenFactor, getCurDebugLoc(),
MVT::Other, &Chains[0], NumValues));
From gohman at apple.com Mon Sep 14 19:14:11 2009
From: gohman at apple.com (Dan Gohman)
Date: Tue, 15 Sep 2009 00:14:11 -0000
Subject: [llvm-commits] [llvm] r81814 - in /llvm/trunk:
lib/Target/X86/X86Instr64bit.td test/CodeGen/X86/cmov-zext.ll
Message-ID: <200909150014.n8F0EBt6024605@zion.cs.uiuc.edu>
Author: djg
Date: Mon Sep 14 19:14:11 2009
New Revision: 81814
URL: http://llvm.org/viewvc/llvm-project?rev=81814&view=rev
Log:
On x86-64, the 32-bit cmov doesn't actually clear the high 32-bit of
its result if the condition is false.
Added:
llvm/trunk/test/CodeGen/X86/cmov-zext.ll
Modified:
llvm/trunk/lib/Target/X86/X86Instr64bit.td
Modified: llvm/trunk/lib/Target/X86/X86Instr64bit.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86Instr64bit.td?rev=81814&r1=81813&r2=81814&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86Instr64bit.td (original)
+++ llvm/trunk/lib/Target/X86/X86Instr64bit.td Mon Sep 14 19:14:11 2009
@@ -387,13 +387,15 @@
[(set GR64:$dst, (zextloadi64i32 addr:$src))]>;
// Any instruction that defines a 32-bit result leaves the high half of the
-// register. Truncate can be lowered to EXTRACT_SUBREG, and CopyFromReg may
-// be copying from a truncate, but any other 32-bit operation will zero-extend
+// register. Truncate can be lowered to EXTRACT_SUBREG. CopyFromReg may
+// be copying from a truncate. And x86's cmov doesn't do anything if the
+// condition is false. But any other 32-bit operation will zero-extend
// up to 64 bits.
def def32 : PatLeaf<(i32 GR32:$src), [{
return N->getOpcode() != ISD::TRUNCATE &&
N->getOpcode() != TargetInstrInfo::EXTRACT_SUBREG &&
- N->getOpcode() != ISD::CopyFromReg;
+ N->getOpcode() != ISD::CopyFromReg &&
+ N->getOpcode() != X86ISD::CMOV;
}]>;
// In the case of a 32-bit def that is known to implicitly zero-extend,
Added: llvm/trunk/test/CodeGen/X86/cmov-zext.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/cmov-zext.ll?rev=81814&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/X86/cmov-zext.ll (added)
+++ llvm/trunk/test/CodeGen/X86/cmov-zext.ll Mon Sep 14 19:14:11 2009
@@ -0,0 +1,19 @@
+; RUN: llc < %s -march=x86-64 | FileCheck %s
+
+; x86's 32-bit cmov doesn't clobber the high 32 bits of the destination
+; if the condition is false. An explicit zero-extend (movl) is needed
+; after the cmov.
+
+; CHECK: cmovne %edi, %esi
+; CHECK-NEXT: movl %esi, %edi
+
+declare void @bar(i64) nounwind
+
+define void @foo(i64 %a, i64 %b, i1 %p) nounwind {
+ %c = trunc i64 %a to i32
+ %d = trunc i64 %b to i32
+ %e = select i1 %p, i32 %c, i32 %d
+ %f = zext i32 %e to i64
+ call void @bar(i64 %f)
+ ret void
+}
From natebegeman at mac.com Mon Sep 14 19:14:29 2009
From: natebegeman at mac.com (Nate Begeman)
Date: Tue, 15 Sep 2009 00:14:29 -0000
Subject: [llvm-commits] [llvm] r81815 -
/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp
Message-ID: <200909150014.n8F0ETD1024652@zion.cs.uiuc.edu>
Author: sampo
Date: Mon Sep 14 19:14:28 2009
New Revision: 81815
URL: http://llvm.org/viewvc/llvm-project?rev=81815&view=rev
Log:
Teach the legalizer to propagate the original alignment of loads and store when
it splits them.
Modified:
llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp?rev=81815&r1=81814&r2=81815&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp Mon Sep 14 19:14:28 2009
@@ -170,7 +170,8 @@
DAG.getUNDEF(N->getBasePtr().getValueType()),
N->getSrcValue(), N->getSrcValueOffset(),
N->getMemoryVT().getVectorElementType(),
- N->isVolatile(), N->getAlignment());
+ N->isVolatile(), N->getAlignment(),
+ N->getOriginalAlignment());
// Legalized the chain result - switch anything that used the old chain to
// use the new one.
@@ -360,7 +361,8 @@
return DAG.getStore(N->getChain(), dl, GetScalarizedVector(N->getOperand(1)),
N->getBasePtr(), N->getSrcValue(), N->getSrcValueOffset(),
- N->isVolatile(), N->getAlignment());
+ N->isVolatile(), N->getAlignment(),
+ N->getOriginalAlignment());
}
@@ -715,13 +717,14 @@
int SVOffset = LD->getSrcValueOffset();
EVT MemoryVT = LD->getMemoryVT();
unsigned Alignment = LD->getAlignment();
+ unsigned OrigAlignment = LD->getOriginalAlignment();
bool isVolatile = LD->isVolatile();
EVT LoMemVT, HiMemVT;
GetSplitDestVTs(MemoryVT, LoMemVT, HiMemVT);
Lo = DAG.getLoad(ISD::UNINDEXED, dl, ExtType, LoVT, Ch, Ptr, Offset,
- SV, SVOffset, LoMemVT, isVolatile, Alignment);
+ SV, SVOffset, LoMemVT, isVolatile, Alignment, OrigAlignment);
unsigned IncrementSize = LoMemVT.getSizeInBits()/8;
Ptr = DAG.getNode(ISD::ADD, dl, Ptr.getValueType(), Ptr,
@@ -729,7 +732,7 @@
SVOffset += IncrementSize;
Alignment = MinAlign(Alignment, IncrementSize);
Hi = DAG.getLoad(ISD::UNINDEXED, dl, ExtType, HiVT, Ch, Ptr, Offset,
- SV, SVOffset, HiMemVT, isVolatile, Alignment);
+ SV, SVOffset, HiMemVT, isVolatile, Alignment, OrigAlignment);
// Build a factor node to remember that this load is independent of the
// other one.
@@ -1079,6 +1082,7 @@
int SVOffset = N->getSrcValueOffset();
EVT MemoryVT = N->getMemoryVT();
unsigned Alignment = N->getAlignment();
+ unsigned OrigAlignment = N->getOriginalAlignment();
bool isVol = N->isVolatile();
SDValue Lo, Hi;
GetSplitVector(N->getOperand(1), Lo, Hi);
@@ -1093,7 +1097,7 @@
LoMemVT, isVol, Alignment);
else
Lo = DAG.getStore(Ch, dl, Lo, Ptr, N->getSrcValue(), SVOffset,
- isVol, Alignment);
+ isVol, Alignment, OrigAlignment);
// Increment the pointer to the other half.
Ptr = DAG.getNode(ISD::ADD, dl, Ptr.getValueType(), Ptr,
@@ -1106,7 +1110,8 @@
isVol, MinAlign(Alignment, IncrementSize));
else
Hi = DAG.getStore(Ch, dl, Hi, Ptr, N->getSrcValue(), SVOffset+IncrementSize,
- isVol, MinAlign(Alignment, IncrementSize));
+ isVol, MinAlign(Alignment, IncrementSize),
+ OrigAlignment);
return DAG.getNode(ISD::TokenFactor, dl, MVT::Other, Lo, Hi);
}
From natebegeman at mac.com Mon Sep 14 19:18:30 2009
From: natebegeman at mac.com (Nate Begeman)
Date: Tue, 15 Sep 2009 00:18:30 -0000
Subject: [llvm-commits] [llvm] r81816 -
/llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
Message-ID: <200909150018.n8F0IUmY025160@zion.cs.uiuc.edu>
Author: sampo
Date: Mon Sep 14 19:18:30 2009
New Revision: 81816
URL: http://llvm.org/viewvc/llvm-project?rev=81816&view=rev
Log:
Substantially speed up combiner-aa in the following ways:
1. Switch from an std::set to a SmallPtrSet for visited chain nodes.
2. Do not force the recursive flattening of token factor nodes, regardless of
use count.
3. Immediately process newly created TokenFactor nodes.
Also, improve combiner-aa by teaching it that loads to non-overlapping offsets
of relatively aligned objects cannot alias.
These changes result in a >5x speedup for combiner-aa on most testcases.
Modified:
llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp?rev=81816&r1=81815&r2=81816&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/DAGCombiner.cpp Mon Sep 14 19:18:30 2009
@@ -239,14 +239,17 @@
/// overlap.
bool isAlias(SDValue Ptr1, int64_t Size1,
const Value *SrcValue1, int SrcValueOffset1,
+ unsigned SrcValueAlign1,
SDValue Ptr2, int64_t Size2,
- const Value *SrcValue2, int SrcValueOffset2) const;
+ const Value *SrcValue2, int SrcValueOffset2,
+ unsigned SrcValueAlign2) const;
/// FindAliasInfo - Extracts the relevant alias information from the memory
/// node. Returns true if the operand was a load.
bool FindAliasInfo(SDNode *N,
SDValue &Ptr, int64_t &Size,
- const Value *&SrcValue, int &SrcValueOffset) const;
+ const Value *&SrcValue, int &SrcValueOffset,
+ unsigned &SrcValueAlignment) const;
/// FindBetterChain - Walk up chain skipping non-aliasing memory nodes,
/// looking for a better chain (aliasing node.)
@@ -886,7 +889,7 @@
break;
case ISD::TokenFactor:
- if ((CombinerAA || Op.hasOneUse()) &&
+ if (Op.hasOneUse() &&
std::find(TFs.begin(), TFs.end(), Op.getNode()) == TFs.end()) {
// Queue up for processing.
TFs.push_back(Op.getNode());
@@ -907,7 +910,7 @@
}
}
}
-
+
SDValue Result;
// If we've change things around then replace token factor.
@@ -4959,7 +4962,10 @@
// Create token factor to keep old chain connected.
SDValue Token = DAG.getNode(ISD::TokenFactor, N->getDebugLoc(),
MVT::Other, Chain, ReplLoad.getValue(1));
-
+
+ // Make sure the new and old chains are cleaned up.
+ AddToWorkList(Token.getNode());
+
// Replace uses with load result and token factor. Don't add users
// to work list.
return CombineTo(N, ReplLoad.getValue(0), Token, false);
@@ -5180,8 +5186,9 @@
// If there is a better chain.
if (Chain != BetterChain) {
- // Replace the chain to avoid dependency.
SDValue ReplStore;
+
+ // Replace the chain to avoid dependency.
if (ST->isTruncatingStore()) {
ReplStore = DAG.getTruncStore(BetterChain, N->getDebugLoc(), Value, Ptr,
ST->getSrcValue(),ST->getSrcValueOffset(),
@@ -5197,6 +5204,9 @@
SDValue Token = DAG.getNode(ISD::TokenFactor, N->getDebugLoc(),
MVT::Other, Chain, ReplStore);
+ // Make sure the new and old chains are cleaned up.
+ AddToWorkList(Token.getNode());
+
// Don't add users to work list.
return CombineTo(N, Token, false);
}
@@ -6103,8 +6113,10 @@
/// overlap.
bool DAGCombiner::isAlias(SDValue Ptr1, int64_t Size1,
const Value *SrcValue1, int SrcValueOffset1,
+ unsigned SrcValueAlign1,
SDValue Ptr2, int64_t Size2,
- const Value *SrcValue2, int SrcValueOffset2) const {
+ const Value *SrcValue2, int SrcValueOffset2,
+ unsigned SrcValueAlign2) const {
// If they are the same then they must be aliases.
if (Ptr1 == Ptr2) return true;
@@ -6122,6 +6134,22 @@
// If we know both bases then they can't alias.
if (KnownBase1 && KnownBase2) return false;
+ // If we know required SrcValue1 and SrcValue2 have relatively large alignment
+ // compared to the size and offset of the access, we may be able to prove they
+ // do not alias. This check is conservative for now to catch cases created by
+ // splitting vector types.
+ if ((SrcValueAlign1 == SrcValueAlign2) &&
+ (SrcValueOffset1 != SrcValueOffset2) &&
+ (Size1 == Size2) && (SrcValueAlign1 > Size1)) {
+ int64_t OffAlign1 = SrcValueOffset1 % SrcValueAlign1;
+ int64_t OffAlign2 = SrcValueOffset2 % SrcValueAlign1;
+
+ // There is no overlap between these relatively aligned accesses of similar
+ // size, return no alias.
+ if ((OffAlign1 + Size1) <= OffAlign2 || (OffAlign2 + Size2) <= OffAlign1)
+ return false;
+ }
+
if (CombinerGlobalAA) {
// Use alias analysis information.
int64_t MinOffset = std::min(SrcValueOffset1, SrcValueOffset2);
@@ -6141,18 +6169,22 @@
/// node. Returns true if the operand was a load.
bool DAGCombiner::FindAliasInfo(SDNode *N,
SDValue &Ptr, int64_t &Size,
- const Value *&SrcValue, int &SrcValueOffset) const {
+ const Value *&SrcValue,
+ int &SrcValueOffset,
+ unsigned &SrcValueAlign) const {
if (LoadSDNode *LD = dyn_cast(N)) {
Ptr = LD->getBasePtr();
Size = LD->getMemoryVT().getSizeInBits() >> 3;
SrcValue = LD->getSrcValue();
SrcValueOffset = LD->getSrcValueOffset();
+ SrcValueAlign = LD->getOriginalAlignment();
return true;
} else if (StoreSDNode *ST = dyn_cast(N)) {
Ptr = ST->getBasePtr();
Size = ST->getMemoryVT().getSizeInBits() >> 3;
SrcValue = ST->getSrcValue();
SrcValueOffset = ST->getSrcValueOffset();
+ SrcValueAlign = ST->getOriginalAlignment();
} else {
llvm_unreachable("FindAliasInfo expected a memory operand");
}
@@ -6165,14 +6197,16 @@
void DAGCombiner::GatherAllAliases(SDNode *N, SDValue OriginalChain,
SmallVector &Aliases) {
SmallVector Chains; // List of chains to visit.
- std::set Visited; // Visited node set.
+ SmallPtrSet Visited; // Visited node set.
// Get alias information for node.
SDValue Ptr;
- int64_t Size = 0;
- const Value *SrcValue = 0;
- int SrcValueOffset = 0;
- bool IsLoad = FindAliasInfo(N, Ptr, Size, SrcValue, SrcValueOffset);
+ int64_t Size;
+ const Value *SrcValue;
+ int SrcValueOffset;
+ unsigned SrcValueAlign;
+ bool IsLoad = FindAliasInfo(N, Ptr, Size, SrcValue, SrcValueOffset,
+ SrcValueAlign);
// Starting off.
Chains.push_back(OriginalChain);
@@ -6184,9 +6218,9 @@
SDValue Chain = Chains.back();
Chains.pop_back();
- // Don't bother if we've been before.
- if (Visited.find(Chain.getNode()) != Visited.end()) continue;
- Visited.insert(Chain.getNode());
+ // Don't bother if we've been before.
+ if (!Visited.insert(Chain.getNode()))
+ continue;
switch (Chain.getOpcode()) {
case ISD::EntryToken:
@@ -6197,16 +6231,19 @@
case ISD::STORE: {
// Get alias information for Chain.
SDValue OpPtr;
- int64_t OpSize = 0;
- const Value *OpSrcValue = 0;
- int OpSrcValueOffset = 0;
+ int64_t OpSize;
+ const Value *OpSrcValue;
+ int OpSrcValueOffset;
+ unsigned OpSrcValueAlign;
bool IsOpLoad = FindAliasInfo(Chain.getNode(), OpPtr, OpSize,
- OpSrcValue, OpSrcValueOffset);
+ OpSrcValue, OpSrcValueOffset,
+ OpSrcValueAlign);
// If chain is alias then stop here.
if (!(IsLoad && IsOpLoad) &&
- isAlias(Ptr, Size, SrcValue, SrcValueOffset,
- OpPtr, OpSize, OpSrcValue, OpSrcValueOffset)) {
+ isAlias(Ptr, Size, SrcValue, SrcValueOffset, SrcValueAlign,
+ OpPtr, OpSize, OpSrcValue, OpSrcValueOffset,
+ OpSrcValueAlign)) {
Aliases.push_back(Chain);
} else {
// Look further up the chain.
@@ -6218,10 +6255,14 @@
}
case ISD::TokenFactor:
- // We have to check each of the operands of the token factor, so we queue
- // then up. Adding the operands to the queue (stack) in reverse order
- // maintains the original order and increases the likelihood that getNode
- // will find a matching token factor (CSE.)
+ // We have to check each of the operands of the token factor for "small"
+ // token factors, so we queue them up. Adding the operands to the queue
+ // (stack) in reverse order maintains the original order and increases the
+ // likelihood that getNode will find a matching token factor (CSE.)
+ if (Chain.getNumOperands() > 16) {
+ Aliases.push_back(Chain);
+ break;
+ }
for (unsigned n = Chain.getNumOperands(); n;)
Chains.push_back(Chain.getOperand(--n));
// Eliminate the token factor if we can.
@@ -6253,13 +6294,8 @@
}
// Construct a custom tailored token factor.
- SDValue NewChain = DAG.getNode(ISD::TokenFactor, N->getDebugLoc(), MVT::Other,
- &Aliases[0], Aliases.size());
-
- // Make sure the old chain gets cleaned up.
- if (NewChain != OldChain) AddToWorkList(OldChain.getNode());
-
- return NewChain;
+ return DAG.getNode(ISD::TokenFactor, N->getDebugLoc(), MVT::Other,
+ &Aliases[0], Aliases.size());
}
// SelectionDAG::Combine - This is the entry point for the file.
From enderby at apple.com Mon Sep 14 19:27:26 2009
From: enderby at apple.com (Kevin Enderby)
Date: Tue, 15 Sep 2009 00:27:26 -0000
Subject: [llvm-commits] [llvm] r81817 - in /llvm/trunk:
lib/Target/ARM/AsmParser/ lib/Target/ARM/AsmParser/ARMAsmParser.cpp
lib/Target/ARM/AsmParser/CMakeLists.txt lib/Target/ARM/AsmParser/Makefile
lib/Target/ARM/Makefile test/MC/AsmParser/arm_word_directive.s
test/MC/AsmParser/directive_values.s test/MC/AsmParser/x86_word_directive.s
Message-ID: <200909150027.n8F0RQUw026432@zion.cs.uiuc.edu>
Author: enderby
Date: Mon Sep 14 19:27:25 2009
New Revision: 81817
URL: http://llvm.org/viewvc/llvm-project?rev=81817&view=rev
Log:
Added the first bits of the ARM target assembler to llvm-mc. For now it only
parses the .word directive as 4 bytes and ARMAsmParser::ParseInstruction will
give an error is called. Broke out the test of the .word directive into two
different test cases, one for x86 and one for arm.
Added:
llvm/trunk/lib/Target/ARM/AsmParser/
llvm/trunk/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
llvm/trunk/lib/Target/ARM/AsmParser/CMakeLists.txt
llvm/trunk/lib/Target/ARM/AsmParser/Makefile
llvm/trunk/test/MC/AsmParser/arm_word_directive.s
llvm/trunk/test/MC/AsmParser/x86_word_directive.s
Modified:
llvm/trunk/lib/Target/ARM/Makefile
llvm/trunk/test/MC/AsmParser/directive_values.s
Added: llvm/trunk/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/AsmParser/ARMAsmParser.cpp?rev=81817&view=auto
==============================================================================
--- llvm/trunk/lib/Target/ARM/AsmParser/ARMAsmParser.cpp (added)
+++ llvm/trunk/lib/Target/ARM/AsmParser/ARMAsmParser.cpp Mon Sep 14 19:27:25 2009
@@ -0,0 +1,93 @@
+//===-- ARMAsmParser.cpp - Parse ARM assembly to MCInst instructions ------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+#include "ARM.h"
+#include "llvm/ADT/SmallVector.h"
+#include "llvm/ADT/Twine.h"
+#include "llvm/MC/MCAsmLexer.h"
+#include "llvm/MC/MCAsmParser.h"
+#include "llvm/MC/MCStreamer.h"
+#include "llvm/MC/MCExpr.h"
+#include "llvm/MC/MCInst.h"
+#include "llvm/Support/SourceMgr.h"
+#include "llvm/Target/TargetRegistry.h"
+#include "llvm/Target/TargetAsmParser.h"
+using namespace llvm;
+
+namespace {
+struct ARMOperand;
+
+class ARMAsmParser : public TargetAsmParser {
+ MCAsmParser &Parser;
+
+private:
+ MCAsmParser &getParser() const { return Parser; }
+
+ MCAsmLexer &getLexer() const { return Parser.getLexer(); }
+
+ void Warning(SMLoc L, const Twine &Msg) { Parser.Warning(L, Msg); }
+
+ bool Error(SMLoc L, const Twine &Msg) { return Parser.Error(L, Msg); }
+
+ bool ParseDirectiveWord(unsigned Size, SMLoc L);
+
+public:
+ ARMAsmParser(const Target &T, MCAsmParser &_Parser)
+ : TargetAsmParser(T), Parser(_Parser) {}
+
+ virtual bool ParseInstruction(const StringRef &Name, MCInst &Inst);
+
+ virtual bool ParseDirective(AsmToken DirectiveID);
+};
+
+} // end anonymous namespace
+
+bool ARMAsmParser::ParseInstruction(const StringRef &Name, MCInst &Inst) {
+ SMLoc Loc = getLexer().getTok().getLoc();
+ Error(Loc, "ARMAsmParser::ParseInstruction currently unimplemented");
+ return true;
+}
+
+bool ARMAsmParser::ParseDirective(AsmToken DirectiveID) {
+ StringRef IDVal = DirectiveID.getIdentifier();
+ if (IDVal == ".word")
+ return ParseDirectiveWord(4, DirectiveID.getLoc());
+ return true;
+}
+
+/// ParseDirectiveWord
+/// ::= .word [ expression (, expression)* ]
+bool ARMAsmParser::ParseDirectiveWord(unsigned Size, SMLoc L) {
+ if (getLexer().isNot(AsmToken::EndOfStatement)) {
+ for (;;) {
+ const MCExpr *Value;
+ if (getParser().ParseExpression(Value))
+ return true;
+
+ getParser().getStreamer().EmitValue(Value, Size);
+
+ if (getLexer().is(AsmToken::EndOfStatement))
+ break;
+
+ // FIXME: Improve diagnostic.
+ if (getLexer().isNot(AsmToken::Comma))
+ return Error(L, "unexpected token in directive");
+ getLexer().Lex();
+ }
+ }
+
+ getLexer().Lex();
+ return false;
+}
+
+// Force static initialization.
+extern "C" void LLVMInitializeARMAsmParser() {
+ RegisterAsmParser X(TheARMTarget);
+ RegisterAsmParser Y(TheThumbTarget);
+}
Added: llvm/trunk/lib/Target/ARM/AsmParser/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/AsmParser/CMakeLists.txt?rev=81817&view=auto
==============================================================================
--- llvm/trunk/lib/Target/ARM/AsmParser/CMakeLists.txt (added)
+++ llvm/trunk/lib/Target/ARM/AsmParser/CMakeLists.txt Mon Sep 14 19:27:25 2009
@@ -0,0 +1,6 @@
+include_directories( ${CMAKE_CURRENT_BINARY_DIR}/.. ${CMAKE_CURRENT_SOURCE_DIR}/.. )
+
+add_llvm_library(LLVMARMAsmParser
+ ARMAsmParser.cpp
+ )
+add_dependencies(LLVMARMAsmParser)
Added: llvm/trunk/lib/Target/ARM/AsmParser/Makefile
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/AsmParser/Makefile?rev=81817&view=auto
==============================================================================
--- llvm/trunk/lib/Target/ARM/AsmParser/Makefile (added)
+++ llvm/trunk/lib/Target/ARM/AsmParser/Makefile Mon Sep 14 19:27:25 2009
@@ -0,0 +1,15 @@
+##===- lib/Target/ARM/AsmParser/Makefile -------------------*- Makefile -*-===##
+#
+# The LLVM Compiler Infrastructure
+#
+# This file is distributed under the University of Illinois Open Source
+# License. See LICENSE.TXT for details.
+#
+##===----------------------------------------------------------------------===##
+LEVEL = ../../../..
+LIBRARYNAME = LLVMARMAsmParser
+
+# Hack: we need to include 'main' ARM target directory to grab private headers
+CPPFLAGS = -I$(PROJ_OBJ_DIR)/.. -I$(PROJ_SRC_DIR)/..
+
+include $(LEVEL)/Makefile.common
Modified: llvm/trunk/lib/Target/ARM/Makefile
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/Makefile?rev=81817&r1=81816&r2=81817&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/Makefile (original)
+++ llvm/trunk/lib/Target/ARM/Makefile Mon Sep 14 19:27:25 2009
@@ -18,6 +18,6 @@
ARMGenDAGISel.inc ARMGenSubtarget.inc \
ARMGenCodeEmitter.inc ARMGenCallingConv.inc
-DIRS = AsmPrinter TargetInfo
+DIRS = AsmPrinter AsmParser TargetInfo
include $(LEVEL)/Makefile.common
Added: llvm/trunk/test/MC/AsmParser/arm_word_directive.s
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/MC/AsmParser/arm_word_directive.s?rev=81817&view=auto
==============================================================================
--- llvm/trunk/test/MC/AsmParser/arm_word_directive.s (added)
+++ llvm/trunk/test/MC/AsmParser/arm_word_directive.s Mon Sep 14 19:27:25 2009
@@ -0,0 +1,6 @@
+@ RUN: llvm-mc -triple arm-unknown-unknown %s | FileCheck %s
+
+@ CHECK: TEST0:
+@ CHECK: .long 3
+TEST0:
+ .word 3
Modified: llvm/trunk/test/MC/AsmParser/directive_values.s
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/MC/AsmParser/directive_values.s?rev=81817&r1=81816&r2=81817&view=diff
==============================================================================
--- llvm/trunk/test/MC/AsmParser/directive_values.s (original)
+++ llvm/trunk/test/MC/AsmParser/directive_values.s Mon Sep 14 19:27:25 2009
@@ -19,8 +19,3 @@
# CHECK: .quad 9
TEST3:
.quad 9
-
-# CHECK: TEST4:
-# CHECK: .short 3
-TEST4:
- .word 3
Added: llvm/trunk/test/MC/AsmParser/x86_word_directive.s
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/MC/AsmParser/x86_word_directive.s?rev=81817&view=auto
==============================================================================
--- llvm/trunk/test/MC/AsmParser/x86_word_directive.s (added)
+++ llvm/trunk/test/MC/AsmParser/x86_word_directive.s Mon Sep 14 19:27:25 2009
@@ -0,0 +1,6 @@
+# RUN: llvm-mc -triple i386-unknown-unknown %s | FileCheck %s
+
+# CHECK: TEST0:
+# CHECK: .short 3
+TEST0:
+ .word 3
From scallanan at apple.com Mon Sep 14 19:35:17 2009
From: scallanan at apple.com (Sean Callanan)
Date: Tue, 15 Sep 2009 00:35:17 -0000
Subject: [llvm-commits] [llvm] r81818 - in /llvm/trunk/lib/Target/X86:
X86InstrFormats.td X86InstrInfo.td
Message-ID: <200909150035.n8F0ZIBH027512@zion.cs.uiuc.edu>
Author: spyffe
Date: Mon Sep 14 19:35:17 2009
New Revision: 81818
URL: http://llvm.org/viewvc/llvm-project?rev=81818&view=rev
Log:
Modified the Intel instruction tables to include
versions of CALL and JMP with segmented addresses
provided in-line, as pairs of immediates.
Modified:
llvm/trunk/lib/Target/X86/X86InstrFormats.td
llvm/trunk/lib/Target/X86/X86InstrInfo.td
Modified: llvm/trunk/lib/Target/X86/X86InstrFormats.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrFormats.td?rev=81818&r1=81817&r2=81818&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86InstrFormats.td (original)
+++ llvm/trunk/lib/Target/X86/X86InstrFormats.td Mon Sep 14 19:35:17 2009
@@ -143,6 +143,24 @@
let Pattern = pattern;
}
+// Templates for instructions that use a 16- or 32-bit segmented address as
+// their only operand: lcall (FAR CALL) and ljmp (FAR JMP)
+//
+// Iseg16 - 16-bit segment selector, 16-bit offset
+// Iseg32 - 16-bit segment selector, 32-bit offset
+
+class Iseg16 o, Format f, dag outs, dag ins, string asm,
+ list pattern> : X86Inst {
+ let Pattern = pattern;
+ let CodeSize = 3;
+}
+
+class Iseg32 o, Format f, dag outs, dag ins, string asm,
+ list pattern> : X86Inst {
+ let Pattern = pattern;
+ let CodeSize = 3;
+}
+
// SSE1 Instruction Templates:
//
// SSI - SSE1 instructions with XS prefix.
Modified: llvm/trunk/lib/Target/X86/X86InstrInfo.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrInfo.td?rev=81818&r1=81817&r2=81818&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86InstrInfo.td (original)
+++ llvm/trunk/lib/Target/X86/X86InstrInfo.td Mon Sep 14 19:35:17 2009
@@ -584,9 +584,17 @@
[(brind GR32:$dst)]>;
def JMP32m : I<0xFF, MRM4m, (outs), (ins i32mem:$dst), "jmp{l}\t{*}$dst",
[(brind (loadi32 addr:$dst))]>;
- def FARJMP16 : I<0xFF, MRM5m, (outs), (ins opaque32mem:$dst),
+
+ def FARJMP16i : Iseg16<0xEA, RawFrm, (outs),
+ (ins i16imm:$seg, i16imm:$off),
+ "ljmp{w}\t$seg, $off", []>, OpSize;
+ def FARJMP32i : Iseg32<0xEA, RawFrm, (outs),
+ (ins i16imm:$seg, i32imm:$off),
+ "ljmp{l}\t$seg, $off", []>;
+
+ def FARJMP16m : I<0xFF, MRM5m, (outs), (ins opaque32mem:$dst),
"ljmp{w}\t{*}$dst", []>, OpSize;
- def FARJMP32 : I<0xFF, MRM5m, (outs), (ins opaque48mem:$dst),
+ def FARJMP32m : I<0xFF, MRM5m, (outs), (ins opaque48mem:$dst),
"ljmp{l}\t{*}$dst", []>;
}
@@ -669,9 +677,16 @@
def CALL32m : I<0xFF, MRM2m, (outs), (ins i32mem:$dst, variable_ops),
"call\t{*}$dst", [(X86call (loadi32 addr:$dst))]>;
- def FARCALL16 : I<0xFF, MRM3m, (outs), (ins opaque32mem:$dst),
+ def FARCALL16i : Iseg16<0x9A, RawFrm, (outs),
+ (ins i16imm:$seg, i16imm:$off),
+ "lcall{w}\t$seg, $off", []>, OpSize;
+ def FARCALL32i : Iseg32<0x9A, RawFrm, (outs),
+ (ins i16imm:$seg, i32imm:$off),
+ "lcall{l}\t$seg, $off", []>;
+
+ def FARCALL16m : I<0xFF, MRM3m, (outs), (ins opaque32mem:$dst),
"lcall{w}\t{*}$dst", []>, OpSize;
- def FARCALL32 : I<0xFF, MRM3m, (outs), (ins opaque48mem:$dst),
+ def FARCALL32m : I<0xFF, MRM3m, (outs), (ins opaque48mem:$dst),
"lcall{l}\t{*}$dst", []>;
}
From natebegeman at mac.com Mon Sep 14 19:38:09 2009
From: natebegeman at mac.com (Nate Begeman)
Date: Tue, 15 Sep 2009 00:38:09 -0000
Subject: [llvm-commits] [llvm] r81819 -
/llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
Message-ID: <200909150038.n8F0c9Kq027893@zion.cs.uiuc.edu>
Author: sampo
Date: Mon Sep 14 19:38:09 2009
New Revision: 81819
URL: http://llvm.org/viewvc/llvm-project?rev=81819&view=rev
Log:
Remove incorrect CSE code from r81813.
Modified:
llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAG.cpp?rev=81819&r1=81818&r2=81819&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAG.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAG.cpp Mon Sep 14 19:38:09 2009
@@ -3682,7 +3682,6 @@
AddNodeIDNode(ID, ISD::LOAD, VTs, Ops, 3);
ID.AddInteger(EVT.getRawBits());
ID.AddInteger(encodeMemSDNodeFlags(ExtType, AM, isVolatile, Alignment));
- ID.AddInteger(OrigAlignment);
void *IP = 0;
if (SDNode *E = CSEMap.FindNodeOrInsertPos(ID, IP))
return SDValue(E, 0);
@@ -3745,7 +3744,6 @@
ID.AddInteger(VT.getRawBits());
ID.AddInteger(encodeMemSDNodeFlags(false, ISD::UNINDEXED,
isVolatile, Alignment));
- ID.AddInteger(OrigAlignment);
void *IP = 0;
if (SDNode *E = CSEMap.FindNodeOrInsertPos(ID, IP))
return SDValue(E, 0);
From wendling at apple.com Mon Sep 14 20:02:22 2009
From: wendling at apple.com (Bill Wendling)
Date: Mon, 14 Sep 2009 18:02:22 -0700
Subject: [llvm-commits] [llvm-gcc-4.2] r81788 -
/llvm-gcc-4.2/trunk/gcc/testsuite/g++.apple/eh1.C
In-Reply-To: <5650EAC4-4B8F-4FEB-BE0A-AF5E0FE2A101@apple.com>
References: <200909142113.n8ELDnQK000590@zion.cs.uiuc.edu>
<0F0E8899-5FF6-4605-8F4C-492718DC94E4@apple.com>
<5650EAC4-4B8F-4FEB-BE0A-AF5E0FE2A101@apple.com>
Message-ID: <5F4B670F-0A52-4107-9805-2DCA43755206@apple.com>
On Sep 14, 2009, at 2:58 PM, Mike Stump wrote:
> On Sep 14, 2009, at 2:39 PM, Eric Christopher wrote:
>> Mmm.. either way. I'm happy to revert as it's a bug by that
>> definition :)
>
> Reversion is best I think as I suspect there are many failures in
> the testsuite. The thing being tested is actually a feature of
> gcc. Testing for a non-feature, would be odd. If you wanted to
> test results to be cleaner, you can mark it as expected. I can dig
> up the older radar number for when we switched gcc to text, if you
> want (please don't ask though).
No need. I have it in the radar I'm working on already to switch to
__TEXT.
-bw
From gohman at apple.com Mon Sep 14 20:22:01 2009
From: gohman at apple.com (Dan Gohman)
Date: Tue, 15 Sep 2009 01:22:01 -0000
Subject: [llvm-commits] [llvm] r81821 - in /llvm/trunk:
lib/Target/X86/X86ISelDAGToDAG.cpp test/CodeGen/X86/combiner-aa-1.ll
Message-ID: <200909150122.n8F1M1kC000958@zion.cs.uiuc.edu>
Author: djg
Date: Mon Sep 14 20:22:01 2009
New Revision: 81821
URL: http://llvm.org/viewvc/llvm-project?rev=81821&view=rev
Log:
Don't pull a load through a callseq_start if the load's chain
has multiple uses, as one of the other uses may be on a path
to a different node above the callseq_start, because that
leads to a cyclic graph. This problem is exposed when
-combiner-global-alias-analysis is used. This fixes PR4880.
Added:
llvm/trunk/test/CodeGen/X86/combiner-aa-1.ll
Modified:
llvm/trunk/lib/Target/X86/X86ISelDAGToDAG.cpp
Modified: llvm/trunk/lib/Target/X86/X86ISelDAGToDAG.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86ISelDAGToDAG.cpp?rev=81821&r1=81820&r2=81821&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86ISelDAGToDAG.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86ISelDAGToDAG.cpp Mon Sep 14 20:22:01 2009
@@ -447,7 +447,8 @@
if (Chain.getOperand(0).getNode() == Callee.getNode())
return true;
if (Chain.getOperand(0).getOpcode() == ISD::TokenFactor &&
- Callee.getValue(1).isOperandOf(Chain.getOperand(0).getNode()))
+ Callee.getValue(1).isOperandOf(Chain.getOperand(0).getNode()) &&
+ Callee.getValue(1).hasOneUse())
return true;
return false;
}
Added: llvm/trunk/test/CodeGen/X86/combiner-aa-1.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/combiner-aa-1.ll?rev=81821&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/X86/combiner-aa-1.ll (added)
+++ llvm/trunk/test/CodeGen/X86/combiner-aa-1.ll Mon Sep 14 20:22:01 2009
@@ -0,0 +1,23 @@
+; RUN: llc < %s --combiner-alias-analysis --combiner-global-alias-analysis
+; PR4880
+
+target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64-f80:32:32"
+target triple = "i386-pc-linux-gnu"
+
+%struct.alst_node = type { %struct.node }
+%struct.arg_node = type { %struct.node, i8*, %struct.alst_node* }
+%struct.arglst_node = type { %struct.alst_node, %struct.arg_node*, %struct.arglst_node* }
+%struct.lam_node = type { %struct.alst_node, %struct.arg_node*, %struct.alst_node* }
+%struct.node = type { i32 (...)**, %struct.node* }
+
+define i32 @._ZN8lam_node18resolve_name_clashEP8arg_nodeP9alst_node._ZNK8lam_nodeeqERK8exp_node._ZN11arglst_nodeD0Ev(%struct.lam_node* %this.this, %struct.arg_node* %outer_arg, %struct.alst_node* %env.cmp, %struct.arglst_node* %this, i32 %functionID) {
+comb_entry:
+ %.SV59 = alloca %struct.node* ; <%struct.node**> [#uses=1]
+ %0 = load i32 (...)*** null, align 4 ; [#uses=1]
+ %1 = getelementptr inbounds i32 (...)** %0, i32 3 ; [#uses=1]
+ %2 = load i32 (...)** %1, align 4 ; [#uses=1]
+ store %struct.node* undef, %struct.node** %.SV59
+ %3 = bitcast i32 (...)* %2 to i32 (%struct.node*)* ; [#uses=1]
+ %4 = tail call i32 %3(%struct.node* undef) ; [#uses=0]
+ unreachable
+}
From evan.cheng at apple.com Mon Sep 14 20:32:25 2009
From: evan.cheng at apple.com (Evan Cheng)
Date: Mon, 14 Sep 2009 18:32:25 -0700
Subject: [llvm-commits] [llvm] r81657 - in /llvm/trunk:
lib/Target/ARM/ARMRegisterInfo.td
test/CodeGen/ARM/2009-09-13-InvalidSubreg.ll
In-Reply-To: <200909130059.n8D0xhIF024496@zion.cs.uiuc.edu>
References: <200909130059.n8D0xhIF024496@zion.cs.uiuc.edu>
Message-ID:
On Sep 12, 2009, at 5:59 PM, Anton Korobeynikov wrote:
>
> +
> +// Dummy f32 regclass to represent impossible subreg indices.
> +def SPR_INVALID : RegisterClass<"ARM", [f32], 32, [SDummy]> {
> + let CopyCost = -1;
> +}
> +
Hi Anton,
Could you explain why this is needed?
Evan
> // Scalar double precision floating point / generic 64-bit vector
> register
> // class.
> // ARM requires only word alignment for double. It's more performant
> if it
> @@ -262,7 +274,7 @@
> D8, D9, D10, D11, D12, D13, D14, D15,
> D16, D17, D18, D19, D20, D21, D22, D23,
> D24, D25, D26, D27, D28, D29, D30, D31]> {
> - let SubRegClassList = [SPR, SPR];
> + let SubRegClassList = [SPR_INVALID, SPR_INVALID];
> let MethodProtos = [{
> iterator allocation_order_begin(const MachineFunction &MF) const;
> iterator allocation_order_end(const MachineFunction &MF) const;
> @@ -317,14 +329,22 @@
> // operations
> def DPR_8 : RegisterClass<"ARM", [f64, v4i16, v2f32], 64,
> [D0, D1, D2, D3, D4, D5, D6, D7]> {
> - let SubRegClassList = [SPR, SPR];
> + let SubRegClassList = [SPR_8, SPR_8];
> }
>
> // Generic 128-bit vector register class.
> def QPR : RegisterClass<"ARM", [v16i8, v8i16, v4i32, v2i64, v4f32,
> v2f64], 128,
> [Q0, Q1, Q2, Q3, Q4, Q5, Q6, Q7,
> Q8, Q9, Q10, Q11, Q12, Q13, Q14, Q15]> {
> - let SubRegClassList = [SPR, SPR, SPR, SPR, DPR, DPR];
> + let SubRegClassList = [SPR_INVALID, SPR_INVALID, SPR_INVALID,
> SPR_INVALID,
> + DPR, DPR];
> +}
> +
> +// Subset of QPR that have 32-bit SPR subregs.
> +def QPR_VFP2 : RegisterClass<"ARM", [v16i8, v8i16, v4i32, v2i64,
> v4f32, v2f64],
> + 128,
> + [Q0, Q1, Q2, Q3, Q4, Q5, Q6, Q7]
> > {
> + let SubRegClassList = [SPR, SPR, SPR, SPR, DPR_VFP2, DPR_VFP2];
> }
>
> // Subset of QPR that have 32-bit SPR subregs.
>
> Added: llvm/trunk/test/CodeGen/ARM/2009-09-13-InvalidSubreg.ll
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/ARM/2009-09-13-InvalidSubreg.ll?rev=81657&view=auto
>
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- llvm/trunk/test/CodeGen/ARM/2009-09-13-InvalidSubreg.ll (added)
> +++ llvm/trunk/test/CodeGen/ARM/2009-09-13-InvalidSubreg.ll Sat Sep
> 12 19:59:43 2009
> @@ -0,0 +1,61 @@
> +; RUN: llc -mattr=+neon < %s
> +; PR4965
> +target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-
> i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64"
> +target triple = "armv7-eabi"
> +
> +%struct.fr = type { [6 x %struct.pl] }
> +%struct.obb = type { %"struct.m4", %"struct.p3" }
> +%struct.pl = type { %"struct.p3" }
> +%"struct.m4" = type { %"struct.p3", %"struct.p3", %"struct.p3",
> %"struct.p3" }
> +%"struct.p3" = type { <4 x float> }
> +
> +declare <2 x float> @llvm.arm.neon.vpadd.v2f32(<2 x float>, <2 x
> float>) nounwind readnone
> +
> +define arm_aapcs_vfpcc i8 @foo(%struct.fr* nocapture %this,
> %struct.obb* %box) nounwind {
> +entry:
> + %val.i.i = load <4 x float>* undef ; <<4 x float>>
> [#uses=1]
> + %val2.i.i = load <4 x float>* null ; <<4 x float>>
> [#uses=1]
> + %elt3.i.i = getelementptr inbounds %struct.obb* %box, i32 0, i32
> 0, i32 2, i32 0 ; <<4 x float>*> [#uses=1]
> + %val4.i.i = load <4 x float>* %elt3.i.i ; <<4 x float>>
> [#uses=1]
> + %0 = shufflevector <2 x float> undef, <2 x float>
> zeroinitializer, <4 x i32> ; <<4 x
> float>> [#uses=1]
> + %1 = fadd <4 x float> undef, zeroinitializer ; <<4 x float>>
> [#uses=1]
> + br label %bb33
> +
> +bb: ; preds = %bb33
> + %2 = fmul <4 x float> %val.i.i, undef ; <<4 x float>>
> [#uses=1]
> + %3 = fmul <4 x float> %val2.i.i, undef ; <<4 x float>>
> [#uses=1]
> + %4 = fadd <4 x float> %3, %2 ; <<4 x float>>
> [#uses=1]
> + %5 = fmul <4 x float> %val4.i.i, undef ; <<4 x float>>
> [#uses=1]
> + %6 = fadd <4 x float> %5, %4 ; <<4 x float>>
> [#uses=1]
> + %7 = bitcast <4 x float> %6 to <4 x i32> ; <<4 x i32>>
> [#uses=1]
> + %8 = and <4 x i32> %7, -2147483648, i32 -2147483648> ; <<4 x i32>> [#uses=1]
> + %9 = or <4 x i32> %8, undef ; <<4 x i32>>
> [#uses=1]
> + %10 = bitcast <4 x i32> %9 to <4 x float> ; <<4 x float>>
> [#uses=1]
> + %11 = shufflevector <4 x float> %10, <4 x float> undef, <2 x i32>
> ; <<2 x float>> [#uses=1]
> + %12 = shufflevector <2 x float> %11, <2 x float> undef, <4 x i32>
> zeroinitializer ; <<4 x float>> [#uses=1]
> + %13 = fmul <4 x float> undef, %12 ; <<4 x float>>
> [#uses=1]
> + %14 = fmul <4 x float> %0, undef ; <<4 x float>>
> [#uses=1]
> + %15 = fadd <4 x float> %14, %13 ; <<4 x float>>
> [#uses=1]
> + %16 = fadd <4 x float> undef, %15 ; <<4 x float>>
> [#uses=1]
> + %17 = fadd <4 x float> %1, %16 ; <<4 x float>>
> [#uses=1]
> + %18 = fmul <4 x float> zeroinitializer, %17 ; <<4 x float>>
> [#uses=1]
> + %19 = insertelement <4 x float> %18, float 0.000000e+00, i32 3 ;
> <<4 x float>> [#uses=2]
> + %20 = shufflevector <4 x float> %19, <4 x float> undef, <2 x i32>
> ; <<2 x float>> [#uses=1]
> + %21 = shufflevector <4 x float> %19, <4 x float> undef, <2 x i32>
> ; <<2 x float>> [#uses=1]
> + %22 = tail call <2 x float> @llvm.arm.neon.vpadd.v2f32(<2 x
> float> %20, <2 x float> %21) nounwind ; <<2 x float>> [#uses=2]
> + %23 = tail call <2 x float> @llvm.arm.neon.vpadd.v2f32(<2 x
> float> %22, <2 x float> %22) nounwind ; <<2 x float>> [#uses=2]
> + %24 = shufflevector <2 x float> %23, <2 x float> %23, <4 x i32>
> zeroinitializer ; <<4 x float>> [#uses=1]
> + %25 = fadd <4 x float> %24, zeroinitializer ; <<4 x float>>
> [#uses=1]
> + %tmp46 = extractelement <4 x float> %25, i32 0 ; [#uses=1]
> + %26 = fcmp olt float %tmp46, 0.000000e+00 ; [#uses=1]
> + br i1 %26, label %bb41, label %bb33
> +
> +bb33: ; preds = %bb,
> %entry
> + br i1 undef, label %bb34, label %bb
> +
> +bb34: ; preds = %bb33
> + ret i8 undef
> +
> +bb41: ; preds = %bb
> + ret i8 1
> +}
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From gohman at apple.com Mon Sep 14 20:41:29 2009
From: gohman at apple.com (Dan Gohman)
Date: Mon, 14 Sep 2009 18:41:29 -0700
Subject: [llvm-commits] [llvm] r80930 - in /llvm/trunk/lib/Target/X86:
X86ISelLowering.cpp X86Instr64bit.td X86InstrInfo.td
In-Reply-To: <4AA00AB1.8080304@free.fr>
References: <200909031718.n83HIqqR031599@zion.cs.uiuc.edu>
<4AA00AB1.8080304@free.fr>
Message-ID: <3AC8C10E-B832-4870-A80F-97C1B3524C7F@apple.com>
On Sep 3, 2009, at 11:28 AM, Duncan Sands wrote:
> Hi Dan,
>
>
>
>> Add a -disable-16bit flag and associated support for experimenting
>> with
>>
>>
>> disabling the use of 16-bit operations on x86. This doesn't yet
>> work for
>>
>>
>> inline asms with 16-bit constraints, vectors with 16-bit elements,
>>
>>
>> trampoline code, and perhaps other obscurities, but it's enough to
>> try
>>
>>
>> some experiments.
>>
>>
>
> not sure why you mention trampoline code here?
All I know is that one of test failures happened to be in the vicinity
of a trampoline setup, and there was nothing else suspicious around.
If -disable-16bit is worth pursuing, I'll do more testing and figure
out what's really going on there.
Dan
From sabre at nondot.org Mon Sep 14 21:22:48 2009
From: sabre at nondot.org (Chris Lattner)
Date: Tue, 15 Sep 2009 02:22:48 -0000
Subject: [llvm-commits] [llvm] r81822 - in /llvm/trunk/test/CodeGen/X86:
cmov-zext.ll cmov.ll commute-cmov.ll
Message-ID: <200909150222.n8F2Mmm9008567@zion.cs.uiuc.edu>
Author: lattner
Date: Mon Sep 14 21:22:47 2009
New Revision: 81822
URL: http://llvm.org/viewvc/llvm-project?rev=81822&view=rev
Log:
merge two cmov tests into one.
Added:
llvm/trunk/test/CodeGen/X86/cmov.ll
- copied, changed from r81821, llvm/trunk/test/CodeGen/X86/commute-cmov.ll
Removed:
llvm/trunk/test/CodeGen/X86/cmov-zext.ll
llvm/trunk/test/CodeGen/X86/commute-cmov.ll
Removed: llvm/trunk/test/CodeGen/X86/cmov-zext.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/cmov-zext.ll?rev=81821&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/X86/cmov-zext.ll (original)
+++ llvm/trunk/test/CodeGen/X86/cmov-zext.ll (removed)
@@ -1,19 +0,0 @@
-; RUN: llc < %s -march=x86-64 | FileCheck %s
-
-; x86's 32-bit cmov doesn't clobber the high 32 bits of the destination
-; if the condition is false. An explicit zero-extend (movl) is needed
-; after the cmov.
-
-; CHECK: cmovne %edi, %esi
-; CHECK-NEXT: movl %esi, %edi
-
-declare void @bar(i64) nounwind
-
-define void @foo(i64 %a, i64 %b, i1 %p) nounwind {
- %c = trunc i64 %a to i32
- %d = trunc i64 %b to i32
- %e = select i1 %p, i32 %c, i32 %d
- %f = zext i32 %e to i64
- call void @bar(i64 %f)
- ret void
-}
Copied: llvm/trunk/test/CodeGen/X86/cmov.ll (from r81821, llvm/trunk/test/CodeGen/X86/commute-cmov.ll)
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/cmov.ll?p2=llvm/trunk/test/CodeGen/X86/cmov.ll&p1=llvm/trunk/test/CodeGen/X86/commute-cmov.ll&r1=81821&r2=81822&rev=81822&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/X86/commute-cmov.ll (original)
+++ llvm/trunk/test/CodeGen/X86/cmov.ll Mon Sep 14 21:22:47 2009
@@ -1,30 +1,48 @@
-; RUN: llc < %s -march=x86 | FileCheck %s
+; RUN: llc < %s -march=x86-64 | FileCheck %s
-define i32 @test1(i32 %x, i32 %n, i32 %w, i32 %v) nounwind readnone {
+define i32 @test1(i32 %x, i32 %n, i32 %w, i32* %vp) nounwind readnone {
entry:
; CHECK: test1:
; CHECK: btl
; CHECK-NEXT: movl $12, %eax
-; CHECK-NEXT: cmovae 16(%esp), %eax
+; CHECK-NEXT: cmovae (%rcx), %eax
; CHECK-NEXT: ret
%0 = lshr i32 %x, %n ; [#uses=1]
%1 = and i32 %0, 1 ; [#uses=1]
%toBool = icmp eq i32 %1, 0 ; [#uses=1]
+ %v = load i32* %vp
%.0 = select i1 %toBool, i32 %v, i32 12 ; [#uses=1]
ret i32 %.0
}
-define i32 @test2(i32 %x, i32 %n, i32 %w, i32 %v) nounwind readnone {
+define i32 @test2(i32 %x, i32 %n, i32 %w, i32* %vp) nounwind readnone {
entry:
; CHECK: test2:
; CHECK: btl
; CHECK-NEXT: movl $12, %eax
-; CHECK-NEXT: cmovb 16(%esp), %eax
+; CHECK-NEXT: cmovb (%rcx), %eax
; CHECK-NEXT: ret
%0 = lshr i32 %x, %n ; [#uses=1]
%1 = and i32 %0, 1 ; [#uses=1]
%toBool = icmp eq i32 %1, 0 ; [#uses=1]
+ %v = load i32* %vp
%.0 = select i1 %toBool, i32 12, i32 %v ; [#uses=1]
ret i32 %.0
}
+
+
+declare void @bar(i64) nounwind
+
+define void @test3(i64 %a, i64 %b, i1 %p) nounwind {
+; CHECK: test3:
+; CHECK: cmovne %edi, %esi
+; CHECK-NEXT: movl %esi, %edi
+
+ %c = trunc i64 %a to i32
+ %d = trunc i64 %b to i32
+ %e = select i1 %p, i32 %c, i32 %d
+ %f = zext i32 %e to i64
+ call void @bar(i64 %f)
+ ret void
+}
Removed: llvm/trunk/test/CodeGen/X86/commute-cmov.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/commute-cmov.ll?rev=81821&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/X86/commute-cmov.ll (original)
+++ llvm/trunk/test/CodeGen/X86/commute-cmov.ll (removed)
@@ -1,30 +0,0 @@
-; RUN: llc < %s -march=x86 | FileCheck %s
-
-define i32 @test1(i32 %x, i32 %n, i32 %w, i32 %v) nounwind readnone {
-entry:
-; CHECK: test1:
-; CHECK: btl
-; CHECK-NEXT: movl $12, %eax
-; CHECK-NEXT: cmovae 16(%esp), %eax
-; CHECK-NEXT: ret
-
- %0 = lshr i32 %x, %n ; [#uses=1]
- %1 = and i32 %0, 1 ; [#uses=1]
- %toBool = icmp eq i32 %1, 0 ; [#uses=1]
- %.0 = select i1 %toBool, i32 %v, i32 12 ; [#uses=1]
- ret i32 %.0
-}
-define i32 @test2(i32 %x, i32 %n, i32 %w, i32 %v) nounwind readnone {
-entry:
-; CHECK: test2:
-; CHECK: btl
-; CHECK-NEXT: movl $12, %eax
-; CHECK-NEXT: cmovb 16(%esp), %eax
-; CHECK-NEXT: ret
-
- %0 = lshr i32 %x, %n ; [#uses=1]
- %1 = and i32 %0, 1 ; [#uses=1]
- %toBool = icmp eq i32 %1, 0 ; [#uses=1]
- %.0 = select i1 %toBool, i32 12, i32 %v ; [#uses=1]
- ret i32 %.0
-}
From sabre at nondot.org Mon Sep 14 21:25:21 2009
From: sabre at nondot.org (Chris Lattner)
Date: Tue, 15 Sep 2009 02:25:21 -0000
Subject: [llvm-commits] [llvm] r81823 - in /llvm/trunk/test/CodeGen/X86:
cmov-i8-eflags.ll cmov.ll select-no-cmov.ll
Message-ID: <200909150225.n8F2PMV1008916@zion.cs.uiuc.edu>
Author: lattner
Date: Mon Sep 14 21:25:21 2009
New Revision: 81823
URL: http://llvm.org/viewvc/llvm-project?rev=81823&view=rev
Log:
merge some more cmov tests into cmov.ll
Removed:
llvm/trunk/test/CodeGen/X86/cmov-i8-eflags.ll
llvm/trunk/test/CodeGen/X86/select-no-cmov.ll
Modified:
llvm/trunk/test/CodeGen/X86/cmov.ll
Removed: llvm/trunk/test/CodeGen/X86/cmov-i8-eflags.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/cmov-i8-eflags.ll?rev=81822&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/X86/cmov-i8-eflags.ll (original)
+++ llvm/trunk/test/CodeGen/X86/cmov-i8-eflags.ll (removed)
@@ -1,61 +0,0 @@
-; RUN: llc -march=x86-64 < %s | FileCheck %s
-; PR4814
-
-; CodeGen shouldn't try to do a setne after an expanded 8-bit conditional
-; move without recomputing EFLAGS, because the expansion of the conditional
-; move with control flow may clobber EFLAGS (e.g., with xor, to set the
-; register to zero).
-
-; The test is a little awkward; the important part is that there's a test before the
-; setne.
-
-target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128"
-
- at g_3 = external global i8 ; [#uses=1]
- at g_96 = external global i8 ; [#uses=2]
- at g_100 = external global i8 ; [#uses=2]
- at _2E_str = external constant [15 x i8], align 1 ; <[15 x i8]*> [#uses=1]
-
-define i32 @main() nounwind {
-entry:
- %0 = load i8* @g_3, align 1 ; [#uses=2]
- %1 = sext i8 %0 to i32 ; [#uses=1]
- %.lobit.i = lshr i8 %0, 7 ; [#uses=1]
- %tmp.i = zext i8 %.lobit.i to i32 ; [#uses=1]
- %tmp.not.i = xor i32 %tmp.i, 1 ; [#uses=1]
- %iftmp.17.0.i.i = ashr i32 %1, %tmp.not.i ; [#uses=1]
- %retval56.i.i = trunc i32 %iftmp.17.0.i.i to i8 ; [#uses=1]
- %2 = icmp eq i8 %retval56.i.i, 0 ; [#uses=2]
- %g_96.promoted.i = load i8* @g_96 ; [#uses=3]
- %3 = icmp eq i8 %g_96.promoted.i, 0 ; [#uses=2]
- br i1 %3, label %func_4.exit.i, label %bb.i.i.i
-
-bb.i.i.i: ; preds = %entry
- %4 = volatile load i8* @g_100, align 1 ; [#uses=0]
- br label %func_4.exit.i
-
-; CHECK: g_100
-; CHECK: testb
-; CHECK: testb %al, %al
-; CHECK-NEXT: setne %al
-; CHECK-NEXT: testb
-
-func_4.exit.i: ; preds = %bb.i.i.i, %entry
- %.not.i = xor i1 %2, true ; [#uses=1]
- %brmerge.i = or i1 %3, %.not.i ; [#uses=1]
- %.mux.i = select i1 %2, i8 %g_96.promoted.i, i8 0 ; [#uses=1]
- br i1 %brmerge.i, label %func_1.exit, label %bb.i.i
-
-bb.i.i: ; preds = %func_4.exit.i
- %5 = volatile load i8* @g_100, align 1 ; [#uses=0]
- br label %func_1.exit
-
-func_1.exit: ; preds = %bb.i.i, %func_4.exit.i
- %g_96.tmp.0.i = phi i8 [ %g_96.promoted.i, %bb.i.i ], [ %.mux.i, %func_4.exit.i ] ; [#uses=2]
- store i8 %g_96.tmp.0.i, i8* @g_96
- %6 = zext i8 %g_96.tmp.0.i to i32 ; [#uses=1]
- %7 = tail call i32 (i8*, ...)* @printf(i8* noalias getelementptr ([15 x i8]* @_2E_str, i64 0, i64 0), i32 %6) nounwind ; [#uses=0]
- ret i32 0
-}
-
-declare i32 @printf(i8* nocapture, ...) nounwind
Modified: llvm/trunk/test/CodeGen/X86/cmov.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/cmov.ll?rev=81823&r1=81822&r2=81823&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/X86/cmov.ll (original)
+++ llvm/trunk/test/CodeGen/X86/cmov.ll Mon Sep 14 21:25:21 2009
@@ -1,4 +1,5 @@
; RUN: llc < %s -march=x86-64 | FileCheck %s
+target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128"
define i32 @test1(i32 %x, i32 %n, i32 %w, i32* %vp) nounwind readnone {
entry:
@@ -46,3 +47,97 @@
call void @bar(i64 %f)
ret void
}
+
+
+
+; CodeGen shouldn't try to do a setne after an expanded 8-bit conditional
+; move without recomputing EFLAGS, because the expansion of the conditional
+; move with control flow may clobber EFLAGS (e.g., with xor, to set the
+; register to zero).
+
+; The test is a little awkward; the important part is that there's a test before the
+; setne.
+; PR4814
+
+
+ at g_3 = external global i8 ; [#uses=1]
+ at g_96 = external global i8 ; [#uses=2]
+ at g_100 = external global i8 ; [#uses=2]
+ at _2E_str = external constant [15 x i8], align 1 ; <[15 x i8]*> [#uses=1]
+
+define i32 @test4() nounwind {
+entry:
+ %0 = load i8* @g_3, align 1 ; [#uses=2]
+ %1 = sext i8 %0 to i32 ; [#uses=1]
+ %.lobit.i = lshr i8 %0, 7 ; [#uses=1]
+ %tmp.i = zext i8 %.lobit.i to i32 ; [#uses=1]
+ %tmp.not.i = xor i32 %tmp.i, 1 ; [#uses=1]
+ %iftmp.17.0.i.i = ashr i32 %1, %tmp.not.i ; [#uses=1]
+ %retval56.i.i = trunc i32 %iftmp.17.0.i.i to i8 ; [#uses=1]
+ %2 = icmp eq i8 %retval56.i.i, 0 ; [#uses=2]
+ %g_96.promoted.i = load i8* @g_96 ; [#uses=3]
+ %3 = icmp eq i8 %g_96.promoted.i, 0 ; [#uses=2]
+ br i1 %3, label %func_4.exit.i, label %bb.i.i.i
+
+bb.i.i.i: ; preds = %entry
+ %4 = volatile load i8* @g_100, align 1 ; [#uses=0]
+ br label %func_4.exit.i
+
+; CHECK: test4:
+; CHECK: g_100
+; CHECK: testb
+; CHECK: testb %al, %al
+; CHECK-NEXT: setne %al
+; CHECK-NEXT: testb
+
+func_4.exit.i: ; preds = %bb.i.i.i, %entry
+ %.not.i = xor i1 %2, true ; [#uses=1]
+ %brmerge.i = or i1 %3, %.not.i ; [#uses=1]
+ %.mux.i = select i1 %2, i8 %g_96.promoted.i, i8 0 ; [#uses=1]
+ br i1 %brmerge.i, label %func_1.exit, label %bb.i.i
+
+bb.i.i: ; preds = %func_4.exit.i
+ %5 = volatile load i8* @g_100, align 1 ; [#uses=0]
+ br label %func_1.exit
+
+func_1.exit: ; preds = %bb.i.i, %func_4.exit.i
+ %g_96.tmp.0.i = phi i8 [ %g_96.promoted.i, %bb.i.i ], [ %.mux.i, %func_4.exit.i ] ; [#uses=2]
+ store i8 %g_96.tmp.0.i, i8* @g_96
+ %6 = zext i8 %g_96.tmp.0.i to i32 ; [#uses=1]
+ %7 = tail call i32 (i8*, ...)* @printf(i8* noalias getelementptr ([15 x i8]* @_2E_str, i64 0, i64 0), i32 %6) nounwind ; [#uses=0]
+ ret i32 0
+}
+
+declare i32 @printf(i8* nocapture, ...) nounwind
+
+
+; Should compile to setcc | -2.
+; rdar://6668608
+define i32 @test5(i32* nocapture %P) nounwind readonly {
+entry:
+; CHECK: test5:
+; CHECK: setg %al
+; CHECK: movzbl %al, %eax
+; CHECK: orl $-2, %eax
+; CHECK: ret
+
+ %0 = load i32* %P, align 4 ; [#uses=1]
+ %1 = icmp sgt i32 %0, 41 ; [#uses=1]
+ %iftmp.0.0 = select i1 %1, i32 -1, i32 -2 ; [#uses=1]
+ ret i32 %iftmp.0.0
+}
+
+define i32 @test6(i32* nocapture %P) nounwind readonly {
+entry:
+; CHECK: test6:
+; CHECK: setl %al
+; CHECK: movzbl %al, %eax
+; CHECK: leal 4(%rax,%rax,8), %eax
+; CHECK: ret
+ %0 = load i32* %P, align 4 ; [#uses=1]
+ %1 = icmp sgt i32 %0, 41 ; [#uses=1]
+ %iftmp.0.0 = select i1 %1, i32 4, i32 13 ; [#uses=1]
+ ret i32 %iftmp.0.0
+}
+
+
Removed: llvm/trunk/test/CodeGen/X86/select-no-cmov.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/select-no-cmov.ll?rev=81822&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/X86/select-no-cmov.ll (original)
+++ llvm/trunk/test/CodeGen/X86/select-no-cmov.ll (removed)
@@ -1,26 +0,0 @@
-; RUN: llc < %s | not grep cmov
-
-target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64-f80:128:128"
-target triple = "i386-apple-darwin7"
-
-; Should compile to setcc | -2.
-; rdar://6668608
-define i32 @test(i32* nocapture %P) nounwind readonly {
-entry:
- %0 = load i32* %P, align 4 ; [#uses=1]
- %1 = icmp sgt i32 %0, 41 ; [#uses=1]
- %iftmp.0.0 = select i1 %1, i32 -1, i32 -2 ; [#uses=1]
- ret i32 %iftmp.0.0
-}
-
-; setl %al
-; movzbl %al, %eax
-; leal 4(%eax,%eax,8), %eax
-define i32 @test2(i32* nocapture %P) nounwind readonly {
-entry:
- %0 = load i32* %P, align 4 ; [#uses=1]
- %1 = icmp sgt i32 %0, 41 ; [#uses=1]
- %iftmp.0.0 = select i1 %1, i32 4, i32 13 ; [#uses=1]
- ret i32 %iftmp.0.0
-}
-
From sabre at nondot.org Mon Sep 14 21:27:23 2009
From: sabre at nondot.org (Chris Lattner)
Date: Tue, 15 Sep 2009 02:27:23 -0000
Subject: [llvm-commits] [llvm] r81824 - in /llvm/trunk/test/CodeGen/X86:
cmov.ll select-i8.ll
Message-ID: <200909150227.n8F2ROrs009182@zion.cs.uiuc.edu>
Author: lattner
Date: Mon Sep 14 21:27:23 2009
New Revision: 81824
URL: http://llvm.org/viewvc/llvm-project?rev=81824&view=rev
Log:
merge one more in.
Removed:
llvm/trunk/test/CodeGen/X86/select-i8.ll
Modified:
llvm/trunk/test/CodeGen/X86/cmov.ll
Modified: llvm/trunk/test/CodeGen/X86/cmov.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/cmov.ll?rev=81824&r1=81823&r2=81824&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/X86/cmov.ll (original)
+++ llvm/trunk/test/CodeGen/X86/cmov.ll Mon Sep 14 21:27:23 2009
@@ -141,3 +141,13 @@
}
+; Don't try to use a 16-bit conditional move to do an 8-bit select,
+; because it isn't worth it. Just use a branch instead.
+define i8 @test7(i1 inreg %c, i8 inreg %a, i8 inreg %b) nounwind {
+; CHECK: test7:
+; CHECK: testb $1, %dil
+; CHECK-NEXT: jne LBB
+
+ %d = select i1 %c, i8 %a, i8 %b
+ ret i8 %d
+}
Removed: llvm/trunk/test/CodeGen/X86/select-i8.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/select-i8.ll?rev=81823&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/X86/select-i8.ll (original)
+++ llvm/trunk/test/CodeGen/X86/select-i8.ll (removed)
@@ -1,12 +0,0 @@
-; RUN: llc < %s -march=x86 > %t
-; RUN: not grep movz %t
-; RUN: not grep cmov %t
-; RUN: grep movb %t | count 2
-
-; Don't try to use a 16-bit conditional move to do an 8-bit select,
-; because it isn't worth it. Just use a branch instead.
-
-define i8 @foo(i1 inreg %c, i8 inreg %a, i8 inreg %b) {
- %d = select i1 %c, i8 %a, i8 %b
- ret i8 %d
-}
From foldr at codedgers.com Mon Sep 14 22:39:48 2009
From: foldr at codedgers.com (Mikhail Glushenkov)
Date: Tue, 15 Sep 2009 03:39:48 -0000
Subject: [llvm-commits] [llvm] r81826 - in /llvm/trunk:
include/llvm/System/Program.h lib/System/Unix/Program.inc
lib/System/Win32/Program.inc
Message-ID: <200909150339.n8F3dn4T018712@zion.cs.uiuc.edu>
Author: foldr
Date: Mon Sep 14 22:39:45 2009
New Revision: 81826
URL: http://llvm.org/viewvc/llvm-project?rev=81826&view=rev
Log:
Get rid of GetProcessId in Win32/Program.inc.
GetProcessId was introduced only in XP. As a bonus, this change makes Program
objects copyable, since Program is now basically a PID.
Modified:
llvm/trunk/include/llvm/System/Program.h
llvm/trunk/lib/System/Unix/Program.inc
llvm/trunk/lib/System/Win32/Program.inc
Modified: llvm/trunk/include/llvm/System/Program.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/System/Program.h?rev=81826&r1=81825&r2=81826&view=diff
==============================================================================
--- llvm/trunk/include/llvm/System/Program.h (original)
+++ llvm/trunk/include/llvm/System/Program.h Mon Sep 14 22:39:45 2009
@@ -29,22 +29,18 @@
/// @since 1.4
/// @brief An abstraction for finding and executing programs.
class Program {
- /// Opaque handle for target specific data.
- void *Data_;
- // Noncopyable.
- Program(const Program& other);
- Program& operator=(const Program& other);
+ unsigned Pid_;
/// @name Methods
/// @{
public:
- Program();
- ~Program();
+ Program() : Pid_(0) {}
+ ~Program() {}
/// Return process ID of this program.
- unsigned GetPid() const;
+ unsigned GetPid() const { return Pid_; }
/// This function executes the program using the \p arguments provided. The
/// invoked program will inherit the stdin, stdout, and stderr file
Modified: llvm/trunk/lib/System/Unix/Program.inc
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/System/Unix/Program.inc?rev=81826&r1=81825&r2=81826&view=diff
==============================================================================
--- llvm/trunk/lib/System/Unix/Program.inc (original)
+++ llvm/trunk/lib/System/Unix/Program.inc Mon Sep 14 22:39:45 2009
@@ -34,15 +34,6 @@
namespace llvm {
using namespace sys;
-Program::Program() : Data_(0) {}
-
-Program::~Program() {}
-
-unsigned Program::GetPid() const {
- uint64_t pid = reinterpret_cast(Data_);
- return static_cast(pid);
-}
-
// This function just uses the PATH environment variable to find the program.
Path
Program::FindProgramByName(const std::string& progName) {
@@ -214,7 +205,7 @@
break;
}
- Data_ = reinterpret_cast(child);
+ Pid_ = child;
return true;
}
@@ -226,7 +217,7 @@
#ifdef HAVE_SYS_WAIT_H
struct sigaction Act, Old;
- if (Data_ == 0) {
+ if (Pid_ == 0) {
MakeErrMsg(ErrMsg, "Process not started!");
return -1;
}
@@ -242,8 +233,7 @@
// Parent process: Wait for the child process to terminate.
int status;
- uint64_t pid = reinterpret_cast(Data_);
- pid_t child = static_cast(pid);
+ pid_t child = Pid_;
while (wait(&status) != child)
if (secondsToWait && errno == EINTR) {
// Kill the child.
@@ -291,15 +281,12 @@
bool
Program::Kill(std::string* ErrMsg) {
- if (Data_ == 0) {
+ if (Pid_ == 0) {
MakeErrMsg(ErrMsg, "Process not started!");
return true;
}
- uint64_t pid64 = reinterpret_cast(Data_);
- pid_t pid = static_cast(pid64);
-
- if (kill(pid, SIGKILL) != 0) {
+ if (kill(Pid_, SIGKILL) != 0) {
MakeErrMsg(ErrMsg, "The process couldn't be killed!");
return true;
}
Modified: llvm/trunk/lib/System/Win32/Program.inc
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/System/Win32/Program.inc?rev=81826&r1=81825&r2=81826&view=diff
==============================================================================
--- llvm/trunk/lib/System/Win32/Program.inc (original)
+++ llvm/trunk/lib/System/Win32/Program.inc Mon Sep 14 22:39:45 2009
@@ -25,21 +25,6 @@
namespace llvm {
using namespace sys;
-Program::Program() : Data_(0) {}
-
-Program::~Program() {
- if (Data_) {
- HANDLE hProcess = reinterpret_cast(Data_);
- CloseHandle(hProcess);
- Data_ = 0;
- }
-}
-
-unsigned Program::GetPid() const {
- HANDLE hProcess = reinterpret_cast(Data_);
- return GetProcessId(hProcess);
-}
-
// This function just uses the PATH environment variable to find the program.
Path
Program::FindProgramByName(const std::string& progName) {
@@ -137,11 +122,6 @@
const Path** redirects,
unsigned memoryLimit,
std::string* ErrMsg) {
- if (Data_) {
- HANDLE hProcess = reinterpret_cast(Data_);
- CloseHandle(Data_);
- Data_ = 0;
- }
if (!path.canExecute()) {
if (ErrMsg)
@@ -269,9 +249,10 @@
path.str() + "'");
return false;
}
- Data_ = reinterpret_cast(pi.hProcess);
+ Pid_ = pi.dwProcessId;
// Make sure these get closed no matter what.
+ AutoHandle hProcess(pi.hProcess);
AutoHandle hThread(pi.hThread);
// Assign the process to a job if a memory limit is defined.
@@ -305,12 +286,17 @@
int
Program::Wait(unsigned secondsToWait,
std::string* ErrMsg) {
- if (Data_ == 0) {
+ if (Pid_ == 0) {
MakeErrMsg(ErrMsg, "Process not started!");
return -1;
}
- HANDLE hProcess = reinterpret_cast(Data_);
+ HANDLE hOpen = OpenProcess(SYNCHRONIZE, FALSE, Pid_);
+ if (hOpen == NULL) {
+ MakeErrMsg(ErrMsg, "OpenProcess failed!");
+ return -1;
+ }
+ AutoHandle hProcess(hOpen);
// Wait for the process to terminate.
DWORD millisecondsToWait = INFINITE;
@@ -341,12 +327,18 @@
bool
Program::Kill(std::string* ErrMsg) {
- if (Data_ == 0) {
+ if (Pid_ == 0) {
MakeErrMsg(ErrMsg, "Process not started!");
return true;
}
- HANDLE hProcess = reinterpret_cast(Data_);
+ HANDLE hOpen = OpenProcess(PROCESS_TERMINATE, FALSE, Pid_);
+ if (hOpen == NULL) {
+ MakeErrMsg(ErrMsg, "OpenProcess failed!");
+ return true;
+ }
+ AutoHandle hProcess(hOpen);
+
if (TerminateProcess(hProcess, 1) == 0) {
MakeErrMsg(ErrMsg, "The process couldn't be killed!");
return true;
From kremenek at apple.com Mon Sep 14 23:06:37 2009
From: kremenek at apple.com (Ted Kremenek)
Date: Tue, 15 Sep 2009 04:06:37 -0000
Subject: [llvm-commits] [llvm] r81827 -
/llvm/trunk/lib/Target/ARM/AsmParser/CMakeLists.txt
Message-ID: <200909150406.n8F46b0d021932@zion.cs.uiuc.edu>
Author: kremenek
Date: Mon Sep 14 23:06:36 2009
New Revision: 81827
URL: http://llvm.org/viewvc/llvm-project?rev=81827&view=rev
Log:
Remove invalid add_dependencies line to unbreak the CMake build.
Modified:
llvm/trunk/lib/Target/ARM/AsmParser/CMakeLists.txt
Modified: llvm/trunk/lib/Target/ARM/AsmParser/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/AsmParser/CMakeLists.txt?rev=81827&r1=81826&r2=81827&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/AsmParser/CMakeLists.txt (original)
+++ llvm/trunk/lib/Target/ARM/AsmParser/CMakeLists.txt Mon Sep 14 23:06:36 2009
@@ -3,4 +3,4 @@
add_llvm_library(LLVMARMAsmParser
ARMAsmParser.cpp
)
-add_dependencies(LLVMARMAsmParser)
+
From kremenek at apple.com Mon Sep 14 23:06:42 2009
From: kremenek at apple.com (Ted Kremenek)
Date: Mon, 14 Sep 2009 21:06:42 -0700
Subject: [llvm-commits] [llvm] r81817 - in /llvm/trunk:
lib/Target/ARM/AsmParser/ lib/Target/ARM/AsmParser/ARMAsmParser.cpp
lib/Target/ARM/AsmParser/CMakeLists.txt
lib/Target/ARM/AsmParser/Makefile lib/Target/ARM/Makefile
test/MC/AsmParser/arm_word_directive.s
test/MC/AsmParser/directive_values.s
test/MC/AsmParser/x86_word_directive.s
In-Reply-To: <200909150027.n8F0RQUw026432@zion.cs.uiuc.edu>
References: <200909150027.n8F0RQUw026432@zion.cs.uiuc.edu>
Message-ID:
On Sep 14, 2009, at 5:27 PM, Kevin Enderby wrote:
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- llvm/trunk/lib/Target/ARM/AsmParser/CMakeLists.txt (added)
> +++ llvm/trunk/lib/Target/ARM/AsmParser/CMakeLists.txt Mon Sep 14
> 19:27:25 2009
> @@ -0,0 +1,6 @@
> +include_directories( ${CMAKE_CURRENT_BINARY_DIR}/.. $
> {CMAKE_CURRENT_SOURCE_DIR}/.. )
> +
> +add_llvm_library(LLVMARMAsmParser
> + ARMAsmParser.cpp
> + )
> +add_dependencies(LLVMARMAsmParser)
>
Hi Kevin,
This last line actually breaks the CMake builds:
CMake Error at lib/Target/ARM/AsmParser/CMakeLists.txt:6
(add_dependencies):
add_dependencies called with incorrect number of arguments
Were you trying to add a specific dependency between the
LLVMARMAsmParser and something else?
I've gone ahead and removed this last line, but I'm not certain if
that is the right thing to do. The CMake build now works, but I'm not
certain if a dependency is suppose to be there.
Ted
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.cs.uiuc.edu/pipermail/llvm-commits/attachments/20090914/be180ee6/attachment.html
From kremenek at apple.com Mon Sep 14 23:17:35 2009
From: kremenek at apple.com (Ted Kremenek)
Date: Tue, 15 Sep 2009 04:17:35 -0000
Subject: [llvm-commits] [llvm] r81828 - /llvm/tags/checker/checker-0.220/
Message-ID: <200909150417.n8F4HZFG023349@zion.cs.uiuc.edu>
Author: kremenek
Date: Mon Sep 14 23:17:34 2009
New Revision: 81828
URL: http://llvm.org/viewvc/llvm-project?rev=81828&view=rev
Log:
Removing checker-0.220.
Removed:
llvm/tags/checker/checker-0.220/
From kremenek at apple.com Mon Sep 14 23:19:24 2009
From: kremenek at apple.com (Ted Kremenek)
Date: Tue, 15 Sep 2009 04:19:24 -0000
Subject: [llvm-commits] [llvm] r81831 - /llvm/tags/checker/checker-0.220/
Message-ID: <200909150419.n8F4JOrs023602@zion.cs.uiuc.edu>
Author: kremenek
Date: Mon Sep 14 23:19:24 2009
New Revision: 81831
URL: http://llvm.org/viewvc/llvm-project?rev=81831&view=rev
Log:
Tagging checker-0.220.
Added:
llvm/tags/checker/checker-0.220/
- copied from r81830, llvm/trunk/
From sabre at nondot.org Mon Sep 14 23:27:29 2009
From: sabre at nondot.org (Chris Lattner)
Date: Tue, 15 Sep 2009 04:27:29 -0000
Subject: [llvm-commits] [llvm] r81833 - /llvm/trunk/test/CodeGen/X86/cmov.ll
Message-ID: <200909150427.n8F4RTxe024619@zion.cs.uiuc.edu>
Author: lattner
Date: Mon Sep 14 23:27:29 2009
New Revision: 81833
URL: http://llvm.org/viewvc/llvm-project?rev=81833&view=rev
Log:
this is failing on linux hosts, force a triple.
Modified:
llvm/trunk/test/CodeGen/X86/cmov.ll
Modified: llvm/trunk/test/CodeGen/X86/cmov.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/cmov.ll?rev=81833&r1=81832&r2=81833&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/X86/cmov.ll (original)
+++ llvm/trunk/test/CodeGen/X86/cmov.ll Mon Sep 14 23:27:29 2009
@@ -1,4 +1,4 @@
-; RUN: llc < %s -march=x86-64 | FileCheck %s
+; RUN: llc < %s -mtriple=x86_64-apple-darwin10 | FileCheck %s
target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128"
define i32 @test1(i32 %x, i32 %n, i32 %w, i32* %vp) nounwind readnone {
From sabre at nondot.org Mon Sep 14 23:37:49 2009
From: sabre at nondot.org (Chris Lattner)
Date: Tue, 15 Sep 2009 04:37:49 -0000
Subject: [llvm-commits] [llvm] r81834 -
/llvm/trunk/include/llvm/ADT/SCCIterator.h
Message-ID: <200909150437.n8F4bnf2025925@zion.cs.uiuc.edu>
Author: lattner
Date: Mon Sep 14 23:37:49 2009
New Revision: 81834
URL: http://llvm.org/viewvc/llvm-project?rev=81834&view=rev
Log:
switch scciterator to use DenseMap instead of std::map
Modified:
llvm/trunk/include/llvm/ADT/SCCIterator.h
Modified: llvm/trunk/include/llvm/ADT/SCCIterator.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/ADT/SCCIterator.h?rev=81834&r1=81833&r2=81834&view=diff
==============================================================================
--- llvm/trunk/include/llvm/ADT/SCCIterator.h (original)
+++ llvm/trunk/include/llvm/ADT/SCCIterator.h Mon Sep 14 23:37:49 2009
@@ -22,7 +22,7 @@
#define LLVM_ADT_SCCITERATOR_H
#include "llvm/ADT/GraphTraits.h"
-#include