[Bug target/44749] mep-elf fails to build

2010-11-11 Thread amylaar at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44749

--- Comment #5 from Jorn Wolfgang Rennecke amylaar at gcc dot gnu.org 
2010-11-11 19:11:51 UTC ---
Author: amylaar
Date: Thu Nov 11 19:11:44 2010
New Revision: 166614

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=166614
Log:
PR target/44749
* config/mep/mep-protos.h (mep_legitimize_reload_address): Always
declare.  Change type of argument four to type int.
(mep_secondary_input_reload_class): Returns enum reg_class.
(mep_secondary_output_reload_class): Likewise.
(mep_function_value): Change types of arguments to cont_tree.
* config/mep/mep.c (mep_legitimize_reload_address): Change type of
argument four to type int.
(mep_secondary_input_reload_class): Returns enum reg_class.
(mep_secondary_output_reload_class): Likewise.
(mep_function_value): Change types of arguments to cont_tree.
* config/mep/mep.h (REGNO_REG_CLASS): Cast return value of
mep_regno_reg_class to enum reg_class.

Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/mep/mep-protos.h
trunk/gcc/config/mep/mep.c
trunk/gcc/config/mep/mep.h


[Bug target/44749] mep-elf fails to build

2010-11-11 Thread amylaar at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44749

Jorn Wolfgang Rennecke amylaar at gcc dot gnu.org changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||FIXED

--- Comment #6 from Jorn Wolfgang Rennecke amylaar at gcc dot gnu.org 
2010-11-11 19:41:42 UTC ---
Patch has been applied to trunk.


[Bug target/44749] mep-elf fails to build

2010-11-03 Thread amylaar at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44749

--- Comment #4 from Jorn Wolfgang Rennecke amylaar at gcc dot gnu.org 
2010-11-03 12:15:16 UTC ---
mep-elf still doesn't build when configured with --enable-werror-always.

gcc -c   -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE  -W -Wall -Wwrite-strings
-Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wmissing-format-attribute
-pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -Werror
-Wold-style-definition -Wc++-compat -fno-common  -DHAVE_CONFIG_H -I. -I.
-I../../gcc/gcc -I../../gcc/gcc/. -I../../gcc/gcc/../include
-I../../gcc/gcc/../libcpp/include  -I../../gcc/gcc/../libdecnumber
-I../../gcc/gcc/../libdecnumber/dpd -I../libdecnumber  -DCLOOG_PPL_BACKEND  
../../gcc/gcc/combine.c -o combine.o
../../gcc/gcc/combine.c: In function ‘subst’:
../../gcc/gcc/combine.c:5056:12: error: enum conversion when passing argument 3
of ‘mep_cannot_change_mode_class’ is invalid in C++ [-Werror=c++-compat]
../../gcc/gcc/config/mep/mep-protos.h:104:13: note: expected ‘enum reg_class’
but argument is of type ‘int’
../../gcc/gcc/combine.c: In function ‘simplify_set’:
../../gcc/gcc/combine.c:6372:9: error: enum conversion when passing argument 3
of ‘mep_cannot_change_mode_class’ is invalid in C++ [-Werror=c++-compat]
../../gcc/gcc/config/mep/mep-protos.h:104:13: note: expected ‘enum reg_class’
but argument is of type ‘int’

combine uses REG_CANNOT_CHANGE_MODE_P, which is defined in hard-reg-set.h:

#define REG_CANNOT_CHANGE_MODE_P(REGN, FROM, TO)  \
 CANNOT_CHANGE_MODE_CLASS (FROM, TO, REGNO_REG_CLASS (REGN))

these macros are defined in mep.h like this:
#define REGNO_REG_CLASS(REGNO) mep_regno_reg_class (REGNO)

#define CANNOT_CHANGE_MODE_CLASS(FROM, TO, CLASS) \
  mep_cannot_change_mode_class (FROM, TO, CLASS)

Unfortunately, argument three of mep_cannot_change_mode_class doesn't
accept (in C++) the result of mep_regno_reg_class:

extern bool mep_cannot_change_mode_class (enum machine_mode, enum machine_mode,
  enum reg_class);

extern int mep_regno_reg_class (int);

it would be better if the two functions could agree on using reg_class_t .

Of course, when fixing this, we later run into PR44765.


[Bug target/44749] mep-elf fails to build

2010-09-14 Thread dj at gcc dot gnu dot org


--- Comment #3 from dj at gcc dot gnu dot org  2010-09-14 07:27 ---
Subject: Bug 44749

Author: dj
Date: Tue Sep 14 07:26:54 2010
New Revision: 164268

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=164268
Log:
PR target/44749
* config/mep/mep-protos.h (mep_save_register_info,
mep_reinit_regs, mep_init_regs): Declare.

* config/mep/mep.c: Move all target definitions to the end of the
file to avoid the need for duplicate declarations.
(mep_save_register_info, mep_reinit_regs, mep_init_regs): New.
(mep_reorg_erepeat): Remove unused variables.
(mep_expand_builtin): Likewise.

* config/mep/mep-pragma.c: Don't include rtl.h.
(INVALID_REGNUM): New.
(mep_pragma_coprocessor_which): Call mep-specific rtl-layer bridge
functions.
(mep_pragma_coprocessor_subclass): Rename class to rclass.
Avoid enum/integer math.

Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/mep/mep-pragma.c
trunk/gcc/config/mep/mep-protos.h
trunk/gcc/config/mep/mep.c


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44749



[Bug target/44749] mep-elf fails to build

2010-09-13 Thread jsm28 at gcc dot gnu dot org


--- Comment #1 from jsm28 at gcc dot gnu dot org  2010-09-13 22:25 ---
Subject: Bug 44749

Author: jsm28
Date: Mon Sep 13 22:25:09 2010
New Revision: 164260

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=164260
Log:
PR target/44749
* config/mep/t-mep (GTM_H): Add insn-constants.h.
* config/mep/mep.c (mep_conditional_register_usage): Take no
parameters.
* config/mep/mep-protos.h (mep_conditional_register_usage): Update
prototype.
* config/mep/mep-pragma.c (CONDITIONAL_REGISTER_USAGE): Update
call to mep_conditional_register_usage.

Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/mep/mep-protos.h
trunk/gcc/config/mep/mep.c
trunk/gcc/config/mep/mep.h
trunk/gcc/config/mep/t-mep


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44749



[Bug target/44749] mep-elf fails to build

2010-09-13 Thread jsm28 at gcc dot gnu dot org


--- Comment #2 from jsm28 at gcc dot gnu dot org  2010-09-13 22:27 ---
Note that while my commit fixes two causes of build failure for this target,
a third cause of failure is still present.  As I noted in my patch submission
http://gcc.gnu.org/ml/gcc-patches/2010-09/msg00664.html

* mep-pragma.c gets a series of errors starting with

  rtl.h:22:9: error: attempt to use poisoned GCC_RTL_H

  because it is being treated as a front-end file but uses rtl.h and
  uses various RTL-related functionality.  I don't know the right fix
  for this issue - for my testing I worked around it with #undef
  IN_GCC_FRONTEND but the right fix is more likely to be moving the
  RTL functionality into mep.c while keeping the code using front-end
  pragma interfaces in mep-pragma.c.  Thus, this patch does not fix
  this issue.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44749



[Bug target/44749] mep-elf fails to build

2010-07-05 Thread amylaar at gcc dot gnu dot org


-- 

amylaar at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
 Ever Confirmed|0   |1
   Last reconfirmed|-00-00 00:00:00 |2010-07-05 19:54:13
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44749