About porting GCC to backends which have a small number of registers. ....

2021-04-11 Thread Basile Starynkevitch
To give just one small practical example, I'm told (by people who are more familiar with GCC internals than I) that it is not feasible with today's GCC to port to backends which have a small number of registers. I think (not sure) that could be attributed to j...@darrington.wattle.id.au - apolo

Porting GCC Ada / GNAT to GNU/Hurd as a GSoC project

2011-04-08 Thread Thomas Schwinge
Hallo! We (that is, GNU Hurd) have a Google Summer of Code project application by Vladimir Gorelov who wants to work on getting GNAT into a functional state on GNU/Hurd, as per . Vladimir says to have several years of Ada ex

Re: porting gcc to new arch: unrecognizable insn

2010-08-02 Thread Gabor Kerenyi
> > If I understand correctly it complains about a move instruction where src > > memory location should be (reg22+reg23). My arch defines: > > #define MAX_REGS_PER_ADDRESS 1 > > the first pseudo reg is 13 > > > > I think the wording of the second sentence in the M_R_P_A documentation > (beginn

Re: porting gcc to new arch: unrecognizable insn

2010-08-02 Thread Dave Korn
On 01/08/2010 16:26, Gabor Kerenyi wrote: > I'm porting GCC 4.4.4 to a new arch and while cross-compiling libgcc I get > the > following error: > ../../../libgcc/../gcc/libgcc2.c: In function ‘__clzsi2’: > ../../../libgcc/../gcc/libgcc2.c:716: error: unrecognizable insn:

porting gcc to new arch: unrecognizable insn

2010-08-01 Thread Gabor Kerenyi
Hi All, I'm porting GCC 4.4.4 to a new arch and while cross-compiling libgcc I get the following error: ../../../libgcc/../gcc/libgcc2.c: In function ‘__clzsi2’: ../../../libgcc/../gcc/libgcc2.c:716: error: unrecognizable insn: (insn 49 48 50 16 ../../../libgcc/../gcc/libgcc2.c:713 (set (r

Re: porting GCC to a micro with a very limited addressing mode --- enforcing a 'register indirect memory operand' through a constraint in md

2010-02-12 Thread Dave Korn
On 10/02/2010 19:19, Sergio Ruocco wrote: > It seems that prologue()/epilogue() are called quite late in the > compiling process, thus new registers cannot be created (no_new_pseudos > assert fires) and/or emit_move_insn() does not go through > LEGITIMIZE_ADDRESS()... will work on this tomorrow...

Re: porting GCC to a micro with a very limited addressing mode --- enforcing a 'register indirect memory operand' through a constraint in md

2010-02-10 Thread Sergio Ruocco
und this wiki note about forcing complex addresses into >>>> registers: http://gcc.gnu.org/wiki/WritingANewBackEnd >>>> >>>> ... >>>> rtx copy_addr_to_reg (rtx x) >>>> Equivalent to copy_to_mode_reg (Pmode, x). For example, this >>&

Re: porting GCC to a micro with a very limited addressing mode --- enforcing a 'register indirect memory operand' through a constraint in md

2010-02-10 Thread Sergio Ruocco
>> if(!no_new_pseudos && GET_CODE(operands[0])==MEM) { >>> if( /* addr in operands[0] == base reg + offset */ ) >>> operands[0] = copy_addr_to_reg ( operands[0] ); >>> } >>> ) >>> >>>

Re: porting GCC to a micro with a very limited addressing mode --- success with LEGITIMATE / LEGITIMIZE_ADDRESS, stuck with ICE !

2010-02-10 Thread Michael Hope
as similar addressing modes - all memory must be >>> accessed by one of two registers and can only be accessed indirectly, >>> indirect with pre increment, and indirect with post increment.  The >>> key is GO_IF_LEGITIMATE_ADDRESS and the legitimate address helper >&g

Re: porting GCC to a micro with a very limited addressing mode --- success with LEGITIMATE / LEGITIMIZE_ADDRESS, stuck with ICE !

2010-02-09 Thread Sergio Ruocco
} >> >> tomi_reg_ok returns true if x is any register when strict checking is >> clear and true if x is one of my addressing registers when strict >> checking is set. >> >> GCC will feed any memory accesses through this function to see if they >> are direc

Re: porting GCC to a micro with a very limited addressing mode --- what to write in LEGITIMATE_ADDRESS, LEGITIMIZE_ADDRESS and micro.md ?!

2010-01-28 Thread Sergio Ruocco
set. > > GCC will feed any memory accesses through this function to see if they > are directly supported, and if not it will break them up into > something smaller and try again. > > Hope that helps, > > -- Michael > > > 2010/1/26 Sergio Ruocco : >> Gabriel Pa

Re: porting GCC to a micro with a very limited addressing mode --- what to write in LEGITIMATE_ADDRESS, LEGITIMIZE_ADDRESS and micro.md ?!

2010-01-25 Thread Michael Hope
Mon, Jan 25, 2010 at 01:34:09PM +0100, Sergio Ruocco wrote: >>> Hi everyone, >>> >>> I am porting GCC to a custom 16-bit microcontroller with very limited >>> addressing modes. Basically, it can only load/store using a (general >>> purpose) register

Re: porting GCC to a micro with a very limited addressing mode --- what to write in LEGITIMATE_ADDRESS, LEGITIMIZE_ADDRESS and micro.md ?!

2010-01-25 Thread Jeff Law
On 01/25/10 11:21, Sergio Ruocco wrote: Gabriel Paubert wrote: On Mon, Jan 25, 2010 at 01:34:09PM +0100, Sergio Ruocco wrote: Hi everyone, I am porting GCC to a custom 16-bit microcontroller with very limited addressing modes. Basically, it can only load/store using a (general

Re: porting GCC to a micro with a very limited addressing mode --- what to write in LEGITIMATE_ADDRESS, LEGITIMIZE_ADDRESS and micro.md ?!

2010-01-25 Thread Sergio Ruocco
Gabriel Paubert wrote: > On Mon, Jan 25, 2010 at 01:34:09PM +0100, Sergio Ruocco wrote: >> Hi everyone, >> >> I am porting GCC to a custom 16-bit microcontroller with very limited >> addressing modes. Basically, it can only load/store using a (general >> purpose)

Re: porting GCC to a micro with a very limited addressing mode --- what to write in LEGITIMATE_ADDRESS, LEGITIMIZE_ADDRESS and micro.md ?!

2010-01-25 Thread Gabriel Paubert
On Mon, Jan 25, 2010 at 01:34:09PM +0100, Sergio Ruocco wrote: > > Hi everyone, > > I am porting GCC to a custom 16-bit microcontroller with very limited > addressing modes. Basically, it can only load/store using a (general > purpose) register as the address, without any offse

porting GCC to a micro with a very limited addressing mode --- what to write in LEGITIMATE_ADDRESS, LEGITIMIZE_ADDRESS and micro.md ?!

2010-01-25 Thread Sergio Ruocco
Hi everyone, I am porting GCC to a custom 16-bit microcontroller with very limited addressing modes. Basically, it can only load/store using a (general purpose) register as the address, without any offset: LOAD (R2) R1; load R1 from memory at address (R2) STORE R1 (R2

Re: Porting GCC 4.4.0 to interix

2009-07-30 Thread Ben Elliston
On Thu, 2009-07-30 at 23:58 +0100, Robert Oeffner wrote: > Until now there is no compiler available for interix that supports OpenMP > and that's what I'm after. As libgomp in GCC so far isn't targeting interix > I have made some changes to libgomp in my copy of the GCC 4.4.0 > distribution. l

Porting GCC 4.4.0 to interix

2009-07-30 Thread Robert Oeffner
Hi, I'm new to this mailing list and hope this is the right one I'm addressing. Lately I have been trying to port gcc and g++ from GCC 4.4.0 to interix (the BSD-like unix subsystem optionally available for WinXP and Vista). The subsystem is shipped with gcc and g++ 3.3 and binutils 2.13 which I

Re: Help on Porting GCC to a new architecture

2009-07-13 Thread sumanth
Hi, Gcc internals is the bible to port any architecture to GCC. Study and analyze the internals first. Apart from internals , gcc-4.3.0/gcc/config/ , here you can find various other architectures which give you a practical feel. These links will be more helpful if you are novice.

Re: Help on Porting GCC to a new architecture

2009-07-13 Thread Rajeshwari Bhat
Hi, I am planning to port gcc 4.3.0 to a new architecture. Can you please help me in doing it. Please send me details on porting, such as: 1. The files to be modified in the gcc source . 2. Steps to build gcc for the new architecture. Thanks in advance. Regards, Rajeshwari

Re: real_format_for_mode / Porting GCC on a new arch

2009-02-25 Thread Richard Guenther
On Wed, Feb 25, 2009 at 4:43 PM, Florent DEFAY wrote: > Hi, > > I would like to know more about REAL_MODE_FORMAT and real_format_for_mode. > > I'm sorry because I already posted this email in gcc-help mailing-list > but there was no answer and maybe its right place is here ? > > I am working on a

real_format_for_mode / Porting GCC on a new arch

2009-02-25 Thread Florent DEFAY
Hi, I would like to know more about REAL_MODE_FORMAT and real_format_for_mode. I'm sorry because I already posted this email in gcc-help mailing-list but there was no answer and maybe its right place is here ? I am working on a port of GCC. The new xgcc generated crashes this way : Program rece

Re: porting gcc

2008-10-20 Thread Ian Lance Taylor
Aurélien Buhrig <[EMAIL PROTECTED]> writes: > We are designing a 16-bit asynchronous microcontroller. I’ve already ported > bfd, binutils (including sid simulator) using cgen, and part of gdb (for asm > debug only) and we are now investigating the best way to have C compiler. > So my questions are

porting gcc

2008-10-20 Thread Aurélien Buhrig
Hi, We are designing a 16-bit asynchronous microcontroller. I’ve already ported bfd, binutils (including sid simulator) using cgen, and part of gdb (for asm debug only) and we are now investigating the best way to have C compiler. So my questions are: 1- How much time do you think it will take to

Re: Porting gcc 4.x on tangent A4

2008-07-21 Thread Joern Rennecke
> I have need to compile code for an old ARC tangent A4 core. > 1) Gcc 3.x does support ARC Tangent-A4 > 2) Gcc 4.x dose support ARC Tangent-A4 Both contain a port which in principle targets the ARCtangent-A4. I don't know if it actually works, it might be subject to bitrot. We at ARC have a mor

Porting gcc 4.x on tangent A4

2008-07-21 Thread Giuseppe Monteleone
Hi all I have need to compile code for an old ARC tangent A4 core. 1) Gcc 3.x does support ARC Tangent-A4 2) Gcc 4.x dose support ARC Tangent-A4 if answer is 'not' for both question i will try to introduce code in arc.md and arc.c files to compile code for ARC Tangent-A4. Is this an hard task

a compiler internal error when porting gcc

2008-05-19 Thread tian xiaonan
Hello, All Now when porting gcc I met a problem, which can cause compiler internal error in emit_move_insn function when I use structure pointer to assign a value to structure member like below: typedef struct MV { int m_I; short m_J; }MV; void main(void) { MV mv1; MV* pmv = &

Re: Fwd: Porting gcc to a new architecture

2008-03-12 Thread Samuel Tardieu
> "Schmave" == Schmave <[EMAIL PROTECTED]> writes: > i was wondering what steps i need to take to port gcc to a new > architecture Did you find something unclear in the GCC documentation? Do you have a specific question? Sam -- Samuel Tardieu -- [EMAIL PROTECTED] -- http://www.rfc1149.ne

Re: Porting gcc

2008-03-11 Thread Ben Elliston
On Wed, 2008-03-12 at 16:56 +1100, Schmave wrote: > Hi I would luke to know what I need to do to port gcc to a new > architecture You can start by reading the GCC internals documentation: http://gcc.gnu.org/onlinedocs/gccint/ You can also look at the source code, in particular, the gcc/confi

Porting gcc

2008-03-11 Thread Schmave
Hi I would luke to know what I need to do to port gcc to a new architecture Thanks

Fwd: Porting gcc to a new architecture

2008-03-11 Thread Schmave
Hi i was wondering what steps i need to take to port gcc to a new architecture thanks!

Re: porting gcc to tic54x

2007-12-18 Thread Ramana Radhakrishnan
> > I have been porting tic54x to gcc. I use gcc-4.2.2 version. I write some > > simplest c54x.h and c54x.c and a empty md, and I > > I think the answer is right there > ^^ IIRC what you need as a bare minimum as a w

Re: porting gcc to tic54x

2007-12-16 Thread Hans-Peter Nilsson
On Wed, 12 Dec 2007, a2220333 wrote: > hi, > I have been porting tic54x to gcc. I use gcc-4.2.2 version. I write some > simplest c54x.h and c54x.c and a empty md, and I I think the answer is right there ^^ > compil

porting gcc to tic54x

2007-12-11 Thread a2220333
hi, I have been porting tic54x to gcc. I use gcc-4.2.2 version. I write some simplest c54x.h and c54x.c and a empty md, and I compile it to generate the tic54x-gcc compiler. But when I execute the compiler I generate I got a segmentation fault error. Is there anything must be define in c54x.c

Re: Porting GCC to new architecture

2007-02-26 Thread Ian Lance Taylor
Alexandre Tzannes <[EMAIL PROTECTED]> writes: > I'm Alex Tzannes and I am porting GCC 4.0.2 to a new experimental parallel > architecture. Here's one issue I don't know how to go about. The ISA of > our machine is based on MIPS (so I made a copy of the MIPS back end

Porting GCC to new architecture

2007-02-25 Thread Alexandre Tzannes
Hi, I'm Alex Tzannes and I am porting GCC 4.0.2 to a new experimental parallel architecture. Here's one issue I don't know how to go about. The ISA of our machine is based on MIPS (so I made a copy of the MIPS back end and have been modifying that). One conceptual difference is t

Re: Porting GCC/ GDB help ::Porting the configuration scripts

2007-02-22 Thread Ian Lance Taylor
Mans <[EMAIL PROTECTED]> writes: > Hi i've been put into a project in which the GDB residing on the host machine > should control the programs running on the target(wic has its (own made) > specific processor); I am very much new into all this and as my first task > : i have been assigned the ta

Porting GCC/ GDB help ::Porting the configuration scripts

2007-02-22 Thread Mans
ripts- 2nd task is creating tdep.c;.h & nat.c;.h files... and so on wic i'l do in the next few weeks... kindly help me on wat all pre-requisites i need to proceed and how shud i proceed.. I shall be grateful -- View this message in context: http://www.nabble.com/Porting-GCC--GDB-help-%3A

Re: porting GCC & GCC backends

2006-09-26 Thread Paul Brook
On Tuesday 26 September 2006 20:09, Dave Korn wrote: > On 26 September 2006 20:01, max blomme wrote: > > I'm attempting to port GCC to our companys 32bit microprocessor, and I'm > > a bit overwhelmed. > > > > Looking through some of the documentation (there's quite a lot of it!) I > > can't seem to

RE: porting GCC & GCC backends

2006-09-26 Thread Dave Korn
On 26 September 2006 20:01, max blomme wrote: > I'm attempting to port GCC to our companys 32bit microprocessor, and I'm > a bit overwhelmed. > > Looking through some of the documentation (there's quite a lot of it!) I > can't seem to find the answers to a few questions. Pardon me if they > seem

porting GCC & GCC backends

2006-09-26 Thread max blomme
I'm attempting to port GCC to our companys 32bit microprocessor, and I'm a bit overwhelmed. Looking through some of the documentation (there's quite a lot of it!) I can't seem to find the answers to a few questions. Pardon me if they seem basic and obvious. We already have an assembler and

Re: Porting GCC to RDOS and C++ issues

2005-12-31 Thread Kai Henningsen
[EMAIL PROTECTED] (Leif Ekblad) wrote on 30.12.05 in <[EMAIL PROTECTED]>: > Mike Stump: > > make will build libgcc for the target, specifically, you should be > > able to cd gcc && make libgcc.a to build it. > > It did when I added --host=rdos to the configuration script and > changed a couple of

Re: Porting GCC to RDOS and C++ issues

2005-12-30 Thread Leif Ekblad
Mike Stump: > make will build libgcc for the target, specifically, you should be > able to cd gcc && make libgcc.a to build it. It did when I added --host=rdos to the configuration script and changed a couple of other files. My only current problem is that since RDOS uses the .exe suffix for exe

Re: Porting GCC to RDOS and C++ issues

2005-12-29 Thread Mike Stump
On Dec 29, 2005, at 1:01 PM, Leif Ekblad wrote: OK, I found unwind-dw2.c in the GCC directory. I also found the object files in the linux host directory, but not in the RDOS cross compilation directory. I cannot run the GCC configuration process natively on RDOS (yet), so I must somehow build

Re: Porting GCC to RDOS and C++ issues

2005-12-29 Thread Leif Ekblad
Where are these functions implemented Mike Stump: grep will show you the code that should be used to build it. unwind- dw2.c is the usual place. OK, I found unwind-dw2.c in the GCC directory. I also found the object files in the linux host directory, but not in the RDOS cross compilation di

Re: Porting GCC to RDOS and C++ issues

2005-12-29 Thread Mike Stump
On Dec 29, 2005, at 11:45 AM, Leif Ekblad wrote: However, now I still get unresolved externals related to C++ exception-handling (_Unwind_resume and so on). mrs $ nm libgcc_s.1.dylib | grep Unwind_Re 8c24 T __Unwind_Resume mrs $ nm libgcc/unwind-dw2.o | grep Unwind_Res 24c0 T __Unwind

Porting GCC to RDOS and C++ issues

2005-12-29 Thread Leif Ekblad
I've successfully ported GCC and Newlib to RDOS. It seems to work with a "hello world" app. However, my main focus is not C, but C++. I found out that libstdc++ didn't compile without modifying it's configuration files to support RDOS. Where do I send patches for libstdc++? To this list? Howe

Re: porting gcc/binutils

2005-12-20 Thread Frank Ch. Eigler
<[EMAIL PROTECTED]> writes: > The original intention was that CGEN would eventually be able to > generate the MD file for GCC. When I last used CGEN 2 years ago, it > was not able to do that at the time, and I suspect the problem is > very complex for real machines [...] There exists a CGEN/SID

RE: porting gcc/binutils

2005-12-20 Thread Meissner, Michael
20, 2005 5:43 PM To: Meissner, Michael Cc: [EMAIL PROTECTED] Subject: RE: porting gcc/binutils Hi Michael, first, thanks for your detailed instructions > If your target is a regular target like a RISC platform, the CGEN system > can be used to simplify building the instructio

Re: porting gcc/binutils

2005-12-20 Thread DJ Delorie
> I have already stumbled over cgen on the net and skimmed the > manual. I have noticed that it uses RTL CPU descriptions, I hope > this code can be reused for gcc machine description file. Nope. The only thing cgen's RTL and gcc's RTL share is the acronym.

RE: porting gcc/binutils

2005-12-20 Thread Andrija Radičević
Hi Michael, first, thanks for your detailed instructions > If your target is a regular target like a RISC platform, the CGEN system > can be used to simplify building the instruction tables: > http://sourceware.org/cgen/ > I have already stumbled over cgen on the net and skimmed the manual.

RE: porting gcc/binutils

2005-12-20 Thread Meissner, Michael
us is for code that you write. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Andrija Radicevic Sent: Wednesday, December 14, 2005 6:31 PM To: [EMAIL PROTECTED] Subject: porting gcc/binutils Hi, I'm trying to port gcc and binutils to a new target a

Re: porting gcc/binutils

2005-12-15 Thread Mauricio Alvarez
.tu-chemnitz.de/pub/2004/0107/data/index.html [2] Extending the porting of the GCC-Backend for TMS320C6x VLIW [3] Porting gcc for dunces. Bye Mauricio Alvarez > > best regards > > Andrija Radicevic >

Re: porting gcc/binutils

2005-12-14 Thread Mike Stump
On Dec 14, 2005, at 3:31 PM, Andrija Radičević wrote: I'm trying to port gcc and binutils to a new target and I hoped to find a brief procedure on that matter on the net, but was unsuccessful. OK, the GCC internals is quite a resourceful document and one can learn a lot by examining the source

porting gcc/binutils

2005-12-14 Thread Andrija Radičević
Hi, I'm trying to port gcc and binutils to a new target and I hoped to find a brief procedure on that matter on the net, but was unsuccessful. OK, the GCC internals is quite a resourceful document and one can learn a lot by examining the source tree, but It would be very helpful if there would be

RE: porting gcc can't compile libgcc2.c

2005-09-01 Thread Dave Korn
Original Message >From: Eric Fisher >Sent: 01 September 2005 09:43 > Hello, > > Here is a question about porting gcc. After I modified machine.md and > other backend files, I can make cc1 and xgcc now. But libgcc2.o still > failed. I'd like to know does we mus

porting gcc can't compile libgcc2.c

2005-09-01 Thread Eric Fisher
Hello, Here is a question about porting gcc. After I modified machine.md and other backend files, I can make cc1 and xgcc now. But libgcc2.o still failed. I'd like to know does we must make libgcc2.o since the target machine don't have float registers and 64bit registers. Thanks a lot. Eric

question in porting gcc front end

2005-05-22 Thread zouq
i write a front-end , and compile it with gcc-3.4.1 source code, and it errors in function rest_of_compilation() void rest_of_compilation (tree decl) { rtx insns; timevar_push (TV_REST_OF_COMPILATION); rtl_register_cfg_hooks (); generating_concat_p = 0; cse_not_expected = ! optimize;