Help required - ICE in GCC for my target

2005-11-30 Thread Shrirang Khishti
Hi all

I am porting GCC compiler to new 16 bit target. I am using GCC-4.0.x

For one of the target specific options, I am using PSI mode for
representing pointers. 
If I compile the following test code with this target specific option
along with any of the optimization options I am getting an ICE.

Command line is 
>>> target-elf-gcc -mlarge -O2 ICE.c -c

=
volatile double  gd[32];

int main ()
{
  int i;
  int j;
  for (i = 0; i < 32; i++)
if (gd[i] !=  i * 4 )/* In this statement If I use loop
invariant instead of 'i' in LHS or RHS of comparison program is getting
compiled */
  abort ();
  exit (0);
}

=

ICE I am getting is :   
internal compiler error: in emit_move_insn, at expr.c:3079


I tried to debug the code and I observed that it occurs in the function
emit move instruction Emit_move_instruction(rtx X,rtx Y).

Modes of X an Y are PSI and SI respectively and because of that it is
failing.

I have also provided RTL's for "extendpsisi" and "truncsipsi" (for
converting between PSI and SI modes).

I also tried to take RTL dump , but didn't get any dump , it is failing
before generating RTL's.

Any pointers/help/direction in regard would be nice.

Is there any target specific stuff I will have to look into?

Thanking in advance

Regards,
Shrirang P Khisti
KPIT Cummins Infosystems Ltd


RE: Help required - ICE in GCC for my target

2005-12-01 Thread Shrirang Khishti
Hi Delorie
  Thank you very much for your reply. 
  I have made the changes as you have mentioned, but I am getting same
error.

Could you please guide where I can look into 

Thanking you in advance
Regards
Shrirang Khisti
KPIT Cummins Infosystems Ltd.


-Original Message-
From: DJ Delorie [mailto:[EMAIL PROTECTED] 
Sent: Thursday, December 01, 2005 11:40 AM
To: Shrirang Khishti
Cc: gcc@gcc.gnu.org
Subject: Re: Help required - ICE in GCC for my target


> I have also provided RTL's for "extendpsisi" and "truncsipsi" (for
> converting between PSI and SI modes).

You need extendpsisi2, truncsipsi2, and zero_extendpsisi2.  The m32c
port uses PSI for pointers also; you can use it as an example.


Porting problem from GCC-4.0 to GCC 4.1

2006-01-25 Thread Shrirang Khishti
Hi all
   I have ported GCC-4.0 for a new target. Initially I started porting
with GCC-3.4 and then shifted to GCC-4.0 without any problems. Now I
want to port same code for GCC-4.1 . As there are some structural
differences in GCC-4.0 and gcc-4.1 back-ends specially regarding
addition of .opt file. I have removed all the macros related to
TARGET_SWITCHES and made appropriate entries in .opt file. With this and
some other changes I build cc1. I have also updated TARGET_DEFAULT macro
in target.h file.  But problem that I found is that if I don't specify
any target specific option target_flags are remaining zero. They are not
getting set as expected for DEFAULT_TARGET and so it is giving me ICE.
   If I explicitly give target specific option which is on DEFAULT, then
I am not having any problems.
   Anything is missing from my side? 
Any help will be appreciated

Thanking in advance
Regards

Shrirang Khisti 
KPIT Cummins Infosystems Ltd. 




Patch - GCC Port for Infineon xc16x

2006-03-03 Thread Shrirang Khishti
Hi all,

  KPIT Cummins is contributing the complete GCC port for Infineon
XC16X 
architecture. We would like to request you to send in your comments 
on this port.

As we are putting our best efforts on this port its quality will

successively improve and fit more and more to the current GNU
standards.
KPIT Cummins has already signed copyright assignment with FSF.

  The XC16X is a new derivative of the popular C16X microcontroller

family that is based on the enhanced C166S V2 architecture
(http://www.infineon.com) it outperforms existing 16-bit solutions.
Impressive DSP performance and advanced interrupt handling combined
with 
an integrated powerful peripheral set and a high performance on-chip

flash makes the XC16X the instrument of choice for demanding
industrial
and automotive applications.

We have already submitted binutils port to FSF and it has got
accepted
   http://sourceware.org/ml/binutils/2006-02/msg00230.html. Along with
this   
   patch you need to apply following patch 
   http://sourceware.org/ml/binutils/2006-03/msg00042.html to binutils

   source so as to build the gcc.


Here is the change log for GCC patch.

GCC Version : gcc-4.2-20060218

Please find following two Patches attached with this mail
Patch_gcc.tar.gz   : Gcc Patch for xc16x
Patch_gcc_configure.tar.gz : Patch for top level configure 

2006-03-03Shrirang Khisti   <[EMAIL PROTECTED]> 
 

*config.sub : Add xc16x entry xc16x*-*-*) so that GCC will
understand new xc16x processor
*configure.in   : Add Entry for xc16x.
*configure  : Regenerate


*gcc/config.gcc : Specify source files of xc16x for building



*gcc/config/xc16x/xc16x.h: New file for xc16x macros
*gcc/config/xc16x/xc16x.c: New file for target specific
C
   routines
*gcc/config/xc16x/xc16x.md   : New file for xc16x machine 
   description
*gcc/config/xc16x/lib1funcs.asm  : New file for library routines

*gcc/config/xc16x/t-xc16x  : New file - target makefile
for 
   xc16x
*gcc/config/xc16x/xc16x-protos.h : New file containing
prototypes of 
   the functions
*gcc/config/xc16x/xc16x-modes.def: New file defining PSI mode
for 
   xc16x -mlarge target
option



*gcc/doc/invoke.texi : Infineon xc16x specific target 
 memory options are added
*gcc/doc/md.texi : Infineon xc16x specific constraints 
 specification
*gcc/doc/install.texi: General information about xc16x
*gcc/doc/extend.texi : Infineon xc16x specific attributes
*gcc/doc/contrib.texi: Added the information about KPIT's
 contribution .




Best Regards
Shrirang Khisti
KPIT Cummins Infosystems Ltd. 




Patch_gcc_configure.tar.gz
Description: Patch_gcc_configure.tar.gz


Patch_gcc.tar.gz
Description: Patch_gcc.tar.gz