Message ID | 1428607654-16888-1-git-send-email-rep.dot.nop@gmail.com |
---|---|
State | New |
Headers | show |
On Thu, Apr 09, 2015 at 09:27:34PM +0200, Bernhard Reutner-Fischer wrote: > gcc/ChangeLog: > > 2015-04-08 Bernhard Reutner-Fischer <aldot@gcc.gnu.org> > > PR target/55143 > * c/c-tree.h (c_default_pointer_mode): Move declaration ... > * c-family/c-common.h (c_default_pointer_mode): ... here. > * c/c-decl.c (c_default_pointer_mode): Move definition ... > * c-family/c-common.c (c_default_pointer_mode): ... here. The ChangeLog is certainly wrong, as both c and c-family have their own ChangeLog files, so you really can't write it using ... on both sides. Jakub
On 9 April 2015 at 21:41, Jakub Jelinek <jakub@redhat.com> wrote: > On Thu, Apr 09, 2015 at 09:27:34PM +0200, Bernhard Reutner-Fischer wrote: >> gcc/ChangeLog: >> >> 2015-04-08 Bernhard Reutner-Fischer <aldot@gcc.gnu.org> >> >> PR target/55143 >> * c/c-tree.h (c_default_pointer_mode): Move declaration ... >> * c-family/c-common.h (c_default_pointer_mode): ... here. >> * c/c-decl.c (c_default_pointer_mode): Move definition ... >> * c-family/c-common.c (c_default_pointer_mode): ... here. > > The ChangeLog is certainly wrong, as both c and c-family have their own > ChangeLog files, so you really can't write it using ... on both sides. So.. modulo leading tabs: gcc/c/ChangeLog: 2015-04-09 Bernhard Reutner-Fischer <aldot@gcc.gnu.org> PR target/55143 * c-decl.c (c_default_pointer_mode): Remove definition. * c-tree.h (c_default_pointer_mode): Remove declaration. gcc/c-family/ChangeLog: 2015-04-09 Bernhard Reutner-Fischer <aldot@gcc.gnu.org> PR target/55143 * c-common.c (c_default_pointer_mode): Add definition. * c-common.h (c_default_pointer_mode): Add declaration. Ok for trunk? thanks,
On Thu, Apr 09, 2015 at 09:57:29PM +0200, Bernhard Reutner-Fischer wrote: > On 9 April 2015 at 21:41, Jakub Jelinek <jakub@redhat.com> wrote: > > On Thu, Apr 09, 2015 at 09:27:34PM +0200, Bernhard Reutner-Fischer wrote: > >> gcc/ChangeLog: > >> > >> 2015-04-08 Bernhard Reutner-Fischer <aldot@gcc.gnu.org> > >> > >> PR target/55143 > >> * c/c-tree.h (c_default_pointer_mode): Move declaration ... > >> * c-family/c-common.h (c_default_pointer_mode): ... here. > >> * c/c-decl.c (c_default_pointer_mode): Move definition ... > >> * c-family/c-common.c (c_default_pointer_mode): ... here. > > > > The ChangeLog is certainly wrong, as both c and c-family have their own > > ChangeLog files, so you really can't write it using ... on both sides. > > So.. modulo leading tabs: > gcc/c/ChangeLog: > > 2015-04-09 Bernhard Reutner-Fischer <aldot@gcc.gnu.org> > > PR target/55143 > * c-decl.c (c_default_pointer_mode): Remove definition. > * c-tree.h (c_default_pointer_mode): Remove declaration. > > gcc/c-family/ChangeLog: > > 2015-04-09 Bernhard Reutner-Fischer <aldot@gcc.gnu.org> > > PR target/55143 > * c-common.c (c_default_pointer_mode): Add definition. > * c-common.h (c_default_pointer_mode): Add declaration. > > Ok for trunk? The c_default_pointer_mode is very ugly hack, but guess at least for now it is ok for trunk. Jakub
On 09/04/15 22:09, Jakub Jelinek wrote: > The c_default_pointer_mode is very ugly hack, but guess at least for > now it is ok for trunk. > > Jakub Could you suggest a better approach ? Tristan.
On Fri, Apr 10, 2015 at 07:42:23AM +0200, Tristan Gingold wrote: > On 09/04/15 22:09, Jakub Jelinek wrote: > > > The c_default_pointer_mode is very ugly hack, but guess at least for > > now it is ok for trunk. > > > > Jakub > > Could you suggest a better approach ? Perhaps a target hook (maybe just a variable in the target hooks)? Jakub
On 10 April 2015 at 08:28, Jakub Jelinek <jakub@redhat.com> wrote: > On Fri, Apr 10, 2015 at 07:42:23AM +0200, Tristan Gingold wrote: >> On 09/04/15 22:09, Jakub Jelinek wrote: >> >> > The c_default_pointer_mode is very ugly hack, but guess at least for >> > now it is ok for trunk. >> > >> > Jakub >> >> Could you suggest a better approach ? > > Perhaps a target hook (maybe just a variable in the target hooks)? I leave that to the maintainers to fix properly. The workaround was now committed as r221968 to trunk to unbreak the build of ia64-hp-vms in config-list.mk. thanks,
diff --git a/gcc/c-family/c-common.c b/gcc/c-family/c-common.c index 456c619..7fe7fa6 100644 --- a/gcc/c-family/c-common.c +++ b/gcc/c-family/c-common.c @@ -67,6 +67,10 @@ along with GCC; see the file COPYING3. If not see cpp_reader *parse_in; /* Declared in c-pragma.h. */ +/* Mode used to build pointers (VOIDmode means ptr_mode). */ + +machine_mode c_default_pointer_mode = VOIDmode; + /* The following symbols are subsumed in the c_global_trees array, and listed here individually for documentation purposes. diff --git a/gcc/c-family/c-common.h b/gcc/c-family/c-common.h index 5b2c5ab..cabf452 100644 --- a/gcc/c-family/c-common.h +++ b/gcc/c-family/c-common.h @@ -358,6 +358,10 @@ struct c_common_resword const unsigned int disable : 16; }; +/* Mode used to build pointers (VOIDmode means ptr_mode). */ + +extern machine_mode c_default_pointer_mode; + /* Extra cpp_ttype values for C++. */ /* A token type for template-ids. If a template-id is processed while diff --git a/gcc/c/c-decl.c b/gcc/c/c-decl.c index e1741f1..e28a294 100644 --- a/gcc/c/c-decl.c +++ b/gcc/c/c-decl.c @@ -168,10 +168,6 @@ static int warn_about_return_type; static bool undef_nested_function; -/* Mode used to build pointers (VOIDmode means ptr_mode). */ - -machine_mode c_default_pointer_mode = VOIDmode; - /* If non-zero, implicit "omp declare target" attribute is added into the attribute lists. */ int current_omp_declare_target_attribute; diff --git a/gcc/c/c-tree.h b/gcc/c/c-tree.h index c879bc7..7a72665 100644 --- a/gcc/c/c-tree.h +++ b/gcc/c/c-tree.h @@ -671,10 +671,6 @@ extern int current_function_returns_null; extern int current_function_returns_abnormally; -/* Mode used to build pointers (VOIDmode means ptr_mode). */ - -extern machine_mode c_default_pointer_mode; - /* In c-decl.c */ /* Tell the binding oracle what kind of binding we are looking for. */