Commit a79420f9 by Martin Liska Committed by Martin Liska

Split part of functionality from lto.c to lto-common.c.

2019-05-06  Martin Liska  <mliska@suse.cz>
	    Hrishikesh Kulkarni  <hrishikeshparag@gmail.com>

	* Make-lang.in: Add lto-common.o.
	* config-lang.in: Likewise for gtfiles.
	* lto-common.c: New file.
	* lto-common.h: New file.
	* lto-lang.c: Include lto-common.h.
	* lto.c: Move most of the functionality
	into lto-common.c file.

Co-Authored-By: Hrishikesh Kulkarni <hrishikeshparag@gmail.com>

From-SVN: r270896
parent 2bf6d935
2019-05-06 Martin Liska <mliska@suse.cz>
Hrishikesh Kulkarni <hrishikeshparag@gmail.com>
* Make-lang.in: Add lto-common.o.
* config-lang.in: Likewise for gtfiles.
* lto-common.c: New file.
* lto-common.h: New file.
* lto-lang.c: Include lto-common.h.
* lto.c: Move most of the functionality
into lto-common.c file.
2019-04-12 Jan Hubicka <hubicka@ucw.cz> 2019-04-12 Jan Hubicka <hubicka@ucw.cz>
* lto.c (do_stream_out): rename to ... * lto.c (do_stream_out): rename to ...
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
# The name of the LTO compiler. # The name of the LTO compiler.
LTO_EXE = lto1$(exeext) LTO_EXE = lto1$(exeext)
# The LTO-specific object files inclued in $(LTO_EXE). # The LTO-specific object files inclued in $(LTO_EXE).
LTO_OBJS = lto/lto-lang.o lto/lto.o lto/lto-object.o attribs.o lto/lto-partition.o lto/lto-symtab.o LTO_OBJS = lto/lto-lang.o lto/lto.o lto/lto-object.o attribs.o lto/lto-partition.o lto/lto-symtab.o lto/lto-common.o
lto_OBJS = $(LTO_OBJS) lto_OBJS = $(LTO_OBJS)
# this is only useful in a LTO bootstrap, but this does not work right # this is only useful in a LTO bootstrap, but this does not work right
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
language="lto" language="lto"
compilers="lto1\$(exeext)" compilers="lto1\$(exeext)"
gtfiles="\$(srcdir)/lto/lto-tree.h \$(srcdir)/lto/lto-lang.c \$(srcdir)/lto/lto.c \$(srcdir)/lto/lto.h" gtfiles="\$(srcdir)/lto/lto-tree.h \$(srcdir)/lto/lto-lang.c \$(srcdir)/lto/lto.c \$(srcdir)/lto/lto.h \$(srcdir)/lto/lto-common.h \$(srcdir)/lto/lto-common.c"
# LTO is a special front end. From a user's perspective it is not # LTO is a special front end. From a user's perspective it is not
# really a language, but a middle end feature. However, the GIMPLE # really a language, but a middle end feature. However, the GIMPLE
......
/* LTO common functions between lto.c and lto-dump.c header file.
Copyright (C) 2018 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
<http://www.gnu.org/licenses/>. */
#ifndef LTO_COMMON_H
#define LTO_COMMON_H
void lto_fe_init (void);
void read_cgraph_and_symbols (unsigned, const char **);
void print_lto_report_1 (void);
extern tree lto_eh_personality_decl;
extern GTY(()) vec<tree, va_gc> *tree_with_vars;
extern const unsigned char *lto_mode_identity_table;
extern tree first_personality_decl;
#endif
...@@ -34,6 +34,7 @@ along with GCC; see the file COPYING3. If not see ...@@ -34,6 +34,7 @@ along with GCC; see the file COPYING3. If not see
#include "debug.h" #include "debug.h"
#include "lto-tree.h" #include "lto-tree.h"
#include "lto.h" #include "lto.h"
#include "lto-common.h"
#include "stringpool.h" #include "stringpool.h"
#include "attribs.h" #include "attribs.h"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment