Rationale for an old TRUNCATE patch

2009-06-16 Thread Adam Nemet
I am trying to understand the checkin by Jeff Law from about 11 years ago: r19204 | law | 1998-04-14 01:04:21 -0700 (Tue, 14 Apr 1998) | 4 lines * combine.c (simplify_rtx, case TRUNCATE): Respect value of TRULY_NOOP_TRUNCATION. Index: combine.c ==

Re: uint64_t alignof odditity on x86

2009-06-16 Thread Ian Lance Taylor
Jan Engelhardt writes: > I noticed that __alignof__(uint64_t) will return 8, while > __alignof__(struct { uint64_t x; }) will give only 4. This > run on a typical 32-bit x86 CPU (GCC config below). > > What I am wondering about is why GCC was coded to give different > alignments here. If aligning

instructions for compiling plugins?

2009-06-16 Thread Basile STARYNKEVITCH
Hello All, I am very glad that plugins are now inside the trunk. I have configured the trunk as suggested in http://gcc.gnu.org/ml/gcc/2009-06/msg00173.html so I invoke it as gcc-trunk Apparently, the goal is to be able to compile (at least some) plugins without having the GCC source tree or

AVR C++ - how to move vtables into FLASH memory

2009-06-16 Thread Tomasz Francuz
I would like to change gcc so AVR C++ port will use FLASH memory instead of SRAM to store virtual function pointers. Does anyone try to do it? I have no experience as gcc developer, so can you head me to appropriate files/literature about this particular problem? TIA.

Re: Address mode offset spill

2009-06-16 Thread daniel tian
Hi, your guys: Here is the cc1 the notation cc1 crashed: mvx_audio_dec_mp3_test.c:112: error: unable to find a register to spill in class 'R0_REG' mvx_audio_dec_mp3_test.c:112: error: this is the insn: (insn 185 134 133 6 (set (reg/f:SI 4 R4 [101]) (const_int 2076 [0x81c])) 4 {load_imm_lo

Re: diagnostics-branch merged into mainline

2009-06-16 Thread Rafael Espindola
2009/6/15 Aldy Hernandez : >> ../../gcc/gcc/config/i386/winnt.c: In function ?i386_pe_encode_section_info?: >> ../../gcc/gcc/config/i386/winnt.c:288: error: too few arguments to >> function ?make_decl_one_only? > > make_decl_one_only expects one argument, and that's what's being fed. > Could you pl

Re: diagnostics-branch merged into mainline

2009-06-16 Thread Kai Tietz
2009/6/16 Rafael Espindola : > 2009/6/15 Aldy Hernandez : >>> ../../gcc/gcc/config/i386/winnt.c: In function >>> ?i386_pe_encode_section_info?: >>> ../../gcc/gcc/config/i386/winnt.c:288: error: too few arguments to >>> function ?make_decl_one_only? >> >> make_decl_one_only expects one argument, an

Re: diagnostics-branch merged into mainline

2009-06-16 Thread Rafael Espindola
> At revision 148493 decl_one_only was changed to take 2 arguments. > Looks like I missed winnt.c. 148492 actually. Fixed in revision 148523: 2009-06-16 Rafael Avila de Espindola * config/i386/winnt.c (i386_pe_encode_section_info): Update call to make_decl_one_only. Cheers,

Re: diagnostics-branch merged into mainline

2009-06-16 Thread Kai Tietz
2009/6/16 Rafael Espindola : >> At revision 148493 decl_one_only was changed to take 2 arguments. >> Looks like I missed winnt.c. > > 148492  actually. Fixed in revision 148523: > > > 2009-06-16  Rafael Avila de Espindola   > >        * config/i386/winnt.c (i386_pe_encode_section_info): Update call

Re: "plugin"-ifying the MELT branch.

2009-06-16 Thread Basile STARYNKEVITCH
Basile STARYNKEVITCH wrote: Can a branch be simply a plugin, or should I close (soon) the melt-branch and start a melt-plugin-branch on the SVN. If I do that, do I need some authorization? from whom? Apparently, nothing very special is required to start a new branch. So I intend to creat

Re: "plugin"-ifying the MELT branch.

2009-06-16 Thread Richard Guenther
On Tue, Jun 16, 2009 at 1:13 PM, Basile STARYNKEVITCH wrote: > Basile STARYNKEVITCH wrote: >> >> >> Can a branch be simply a plugin, or should I close (soon) the melt-branch >> and start a melt-plugin-branch on the SVN. If I do that, do I need some >> authorization? from whom? > > > Apparently, not

Re: "plugin"-ifying the MELT branch.

2009-06-16 Thread Basile STARYNKEVITCH
Richard Guenther wrote: On Tue, Jun 16, 2009 at 1:13 PM, Basile STARYNKEVITCH wrote: Basile STARYNKEVITCH wrote: Can a branch be simply a plugin, or should I close (soon) the melt-branch and start a melt-plugin-branch on the SVN. If I do that, do I need some authorization? from whom?

Re: "plugin"-ifying the MELT branch.

2009-06-16 Thread Joseph S. Myers
On Tue, 16 Jun 2009, Basile STARYNKEVITCH wrote: > I thought on the contrary that is was expected that some code would become FSF > owned plugins? Not without a mechanism for linking plugins in statically on hosts for which we don't support dynamic loading of plugins, and even then it's doubtfu

Re: diagnostics-branch merged into mainline

2009-06-16 Thread Dave Korn
Rafael Espindola wrote: > 2009/6/15 Aldy Hernandez : >>> ../../gcc/gcc/config/i386/winnt.c: In function >>> ?i386_pe_encode_section_info?: >>> ../../gcc/gcc/config/i386/winnt.c:288: error: too few arguments to >>> function ?make_decl_one_only? >> make_decl_one_only expects one argument, and that's

Re: instructions for compiling plugins?

2009-06-16 Thread Rafael Espindola
> Apparently, the goal is to be able to compile (at least some) plugins > without having the GCC source tree or build tree. Correct. > However, I believe we don't have any documentation stating that. At least > not in http://gcc.gnu.org/onlinedocs/gccint/Plugins.html and not in > http://gcc.gnu.o

Help with BLOCK vs BIND_EXPR trees

2009-06-16 Thread Jerry Quinn
(trying again) Hi, all. I have a basic question about GENERIC trees. I'm playing with writing a front end, and find the distinction between BLOCK and BIND_EXPR to be somewhat confusing. In particular, I'm trying to get a handle on how to represent a function in GENERIC form. On the surface the

Questions about VAR_DECL and DECL_EXPR

2009-06-16 Thread Jerry Quinn
Hi, again, I am a little unclear on VAR_DECL and DECL_EXPR. The impression I get from reading the docs is that when a variable is first declared in a function, a VAR_DECL should be created, possibly with DECL_INITIAL() set. What's less clearly stated is what you use for variable references later

Re: diagnostics-branch merged into mainline

2009-06-16 Thread Rafael Espindola
> This is ok, too. I assume you have done a regression test? ;) On the fix patch? The file would not build without it I did test the original patch, but missed the winnt file. Cheers, -- Rafael Avila de Espindola Google | Gordon House | Barrow Street | Dublin 4 | Ireland Registered in Dubl

Re: "plugin"-ifying the MELT branch.

2009-06-16 Thread Basile STARYNKEVITCH
I (Basile) very probably misunderstood what Joseph Myers or Richard Guenther meant. What I might have [mis]understood scares me. This is a request for clarification. Joseph S. Myers wrote: On Tue, 16 Jun 2009, Basile STARYNKEVITCH wrote: I thought on the contrary that is was expected

Re: diagnostics-branch merged into mainline

2009-06-16 Thread Dave Korn
Rafael Espindola wrote: >> This is ok, too. I assume you have done a regression test? ;) > > On the fix patch? The file would not build without it > > I did test the original patch, but missed the winnt file. > > Cheers, I did look at the file myself, but couldn't tell (without studying y

Re: instructions for compiling plugins?

2009-06-16 Thread Basile STARYNKEVITCH
Rafael Espindola wrote: (citing me Basile) Apparently, the goal is to be able to compile (at least some) plugins without having the GCC source tree or build tree. Correct. However, I believe we don't have any documentation stating that. At least not in http://gcc.gnu.org/onlinedocs/gc

Re: Help with BLOCK vs BIND_EXPR trees

2009-06-16 Thread Richard Guenther
On Tue, Jun 16, 2009 at 1:50 PM, Jerry Quinn wrote: > (trying again) > Hi, all.  I have a basic question about GENERIC trees. > > I'm playing with writing a front end, and find the distinction between > BLOCK and BIND_EXPR to be somewhat confusing.  In particular, I'm trying > to get a handle on ho

Re: Questions about VAR_DECL and DECL_EXPR

2009-06-16 Thread Richard Guenther
On Tue, Jun 16, 2009 at 2:14 PM, Jerry Quinn wrote: > Hi, again, > > I am a little unclear on VAR_DECL and DECL_EXPR.  The impression I get > from reading the docs is that when a variable is first declared in a > function, a VAR_DECL should be created, possibly with DECL_INITIAL() > set. > > What's

Re: "plugin"-ifying the MELT branch.

2009-06-16 Thread Richard Guenther
On Tue, Jun 16, 2009 at 2:22 PM, Basile STARYNKEVITCH wrote: > > I (Basile) very probably misunderstood what Joseph Myers or Richard Guenther > meant. What I might have [mis]understood scares me. This is a request for > clarification. > > > Joseph S. Myers wrote: > > >> On Tue, 16 Jun 2009, Basile

Re: Questionable function renaming

2009-06-16 Thread Richard Guenther
On Tue, Jun 16, 2009 at 2:23 PM, Bingfeng Mei wrote: > Hello, > > I came across a function renaming issue in GCC 4.4. > > ~/work/install-x86/bin/gcc -Wall -Winline -O3 -g -D_FILE_OFFSET_BITS=64   > -save-temps -c bzip2.c -fdump-tree-all > > > Function saveInputFileMetaInfo is renamed to T.251 after

RE: Questionable function renaming

2009-06-16 Thread Bingfeng Mei
Is it possible to restore the original name if the copy propagation is not profitable and doesn't go ahead? > -Original Message- > From: Richard Guenther [mailto:richard.guent...@gmail.com] > Sent: 16 June 2009 13:56 > To: Bingfeng Mei > Cc: gcc@gcc.gnu.org > Subject: Re: Questionable f

Re: Questionable function renaming

2009-06-16 Thread Richard Guenther
On Tue, Jun 16, 2009 at 3:01 PM, Bingfeng Mei wrote: > Is it possible to restore the original name if the copy propagation is not > profitable and doesn't go ahead? The calling convention is changed, so I don't see how this is easily possible. Richard. >> -Original Message- >> From: Ric

Re: "plugin"-ifying the MELT branch.

2009-06-16 Thread Joseph S. Myers
On Tue, 16 Jun 2009, Basile STARYNKEVITCH wrote: > > > I thought on the contrary that is was expected that some code would become > > > FSF > > > owned plugins? > > > > > > > Not without a mechanism for linking plugins in statically on hosts for which > > we don't support dynamic loading of

Re: Help with BLOCK vs BIND_EXPR trees

2009-06-16 Thread Jerry Quinn
On Tue, 2009-06-16 at 14:43 +0200, Richard Guenther wrote: > BIND_EXPRs are containers for local variables in the GENERIC > function body (they persist until GIMPLE is lowered). BLOCKs > represent the scope tree of the function (which also refers to > local variables). The BLOCK tree is kept live

Re: Address mode offset spill

2009-06-16 Thread Ian Lance Taylor
daniel tian writes: > mvx_audio_dec_mp3_test.c:112: error: unable to find a register to > spill in class 'R0_REG' > mvx_audio_dec_mp3_test.c:112: error: this is the insn: > (insn 185 134 133 6 (set (reg/f:SI 4 R4 [101]) > (const_int 2076 [0x81c])) 4 {load_imm_low_si} (nil) > (expr_lis

Re: git mirror at gcc.gnu.org

2009-06-16 Thread Jason Merrill
On 06/15/2009 01:22 PM, Bernie Innocenti wrote: On 06/15/09 16:28, Rafael Espindola wrote: It fails with $ git config --add remote.origin.fetch '+refs/remotes/*:refs/remotes/origin/*' $ git fetch fatal: refs/remotes/origin/gcc-4_0-branch tracks both refs/remotes/gcc-4_0-branch and refs/heads/gc

Re: git mirror at gcc.gnu.org

2009-06-16 Thread Daniel Berlin
On Tue, Jun 16, 2009 at 10:17 AM, Jason Merrill wrote: > On 06/15/2009 01:22 PM, Bernie Innocenti wrote: >> >> On 06/15/09 16:28, Rafael Espindola wrote: >>> >>> It fails with >>> >>> $ git config --add remote.origin.fetch >>> '+refs/remotes/*:refs/remotes/origin/*' >>> $ git fetch >>> fatal: refs/

RE: Questionable function renaming

2009-06-16 Thread Bingfeng Mei
Thanks, I didn't notice both functions have different arguments after transformation. However, gprof produces T.251 in its statistics, completely unknown to user. Could GCC use more informative name here, e.g., saveInputFileMetaInfo.251? 50.01 0.01 0.01 24 0.42 0.42 BZ2

Re: Help with BLOCK vs BIND_EXPR trees

2009-06-16 Thread Richard Guenther
On Tue, Jun 16, 2009 at 3:19 PM, Jerry Quinn wrote: > On Tue, 2009-06-16 at 14:43 +0200, Richard Guenther wrote: >> BIND_EXPRs are containers for local variables in the GENERIC >> function body (they persist until GIMPLE is lowered).  BLOCKs >> represent the scope tree of the function (which also r

Re: Questionable function renaming

2009-06-16 Thread Richard Guenther
On Tue, Jun 16, 2009 at 3:49 PM, Bingfeng Mei wrote: > Thanks, I didn't notice both functions have different arguments after > transformation. > However, gprof produces T.251 in its statistics, completely unknown > to user. Could GCC use more informative name here, e.g., > saveInputFileMetaInfo.2

Re: Questionable function renaming

2009-06-16 Thread Martin Jambor
Hi, On Tue, Jun 16, 2009 at 06:49:58AM -0700, Bingfeng Mei wrote: > Thanks, I didn't notice both functions have different arguments after > transformation. > However, gprof produces T.251 in its statistics, completely unknown > to user. Could GCC use more informative name here, e.g., > saveInp

Re: Rationale for an old TRUNCATE patch

2009-06-16 Thread Ian Lance Taylor
Adam Nemet writes: > I am trying to understand the checkin by Jeff Law from about 11 years ago: > >r19204 | law | 1998-04-14 01:04:21 -0700 (Tue, 14 Apr 1998) | 4 lines > > >* combine.c (simplify_rtx, case TRUNCATE): Respect value of >TRULY_NOOP_TRUNCATION. >

Re: AVR C++ - how to move vtables into FLASH memory

2009-06-16 Thread Ian Lance Taylor
Tomasz Francuz writes: > I would like to change gcc so AVR C++ port will use FLASH memory > instead of SRAM to store virtual function pointers. Does anyone try to > do it? I have no experience as gcc developer, so can you head me to > appropriate files/literature about this particular problem? T

Re: Questionable function renaming

2009-06-16 Thread Jakub Jelinek
On Tue, Jun 16, 2009 at 04:34:01PM +0200, Martin Jambor wrote: > Hi, > > On Tue, Jun 16, 2009 at 06:49:58AM -0700, Bingfeng Mei wrote: > > Thanks, I didn't notice both functions have different arguments after > > transformation. > > However, gprof produces T.251 in its statistics, completely un

Re: Questions about VAR_DECL and DECL_EXPR

2009-06-16 Thread Ian Lance Taylor
Jerry Quinn writes: > There is also DECL_EXPR representing local declarations, which appears > to be related. How do these get used and would it even be used in a > C-like language? The VAR_DECL is simply stored in the BLOCK, but in C++, C99, and GNU89, not all variables are declared at the sta

Re: git mirror at gcc.gnu.org

2009-06-16 Thread Jason Merrill
Incidentally, I notice that branches in subdirectories of branches/ are still broken; i.e. ARM apple redhat suse ubuntu, maybe others. I give instructions on the GitMirror page for how to deal with that, but I wonder if it's possible to set it up properly on the mirror instead. Jason

Re: diagnostics-branch merged into mainline

2009-06-16 Thread NightStrike
On Mon, Jun 15, 2009 at 2:18 PM, NightStrike wrote: > On Mon, Jun 15, 2009 at 2:05 PM, Aldy Hernandez wrote: >>> ../../gcc/gcc/config/i386/winnt.c: In function >>> ?i386_pe_encode_section_info?: >>> ../../gcc/gcc/config/i386/winnt.c:288: error: too few arguments to >>> function ?make_decl_one_only

Re: "plugin"-ifying the MELT branch.

2009-06-16 Thread Janis Johnson
On Tue, 2009-06-16 at 14:22 +0200, Basile STARYNKEVITCH wrote: > I (Basile) very probably misunderstood what Joseph Myers or Richard > Guenther meant. What I might have [mis]understood scares me. This is a > request for clarification. > Did I understood that in your view no branch hosted on GCC

Re: "plugin"-ifying the MELT branch.

2009-06-16 Thread Diego Novillo
On Tue, Jun 16, 2009 at 13:10, Janis Johnson wrote: > Basile, people are saying that MELT no longer belongs in a branch of > the GCC repository because now that plug-ins are supported, MELT no > longer needs to modify GCC itself and can be maintained independently. > That does not mean that MELT c

Re: "plugin"-ifying the MELT branch.

2009-06-16 Thread Basile STARYNKEVITCH
Diego Novillo wrote: On Tue, Jun 16, 2009 at 13:10, Janis Johnson wrote: Basile, people are saying that MELT no longer belongs in a branch of the GCC repository because now that plug-ins are supported, MELT no longer needs to modify GCC itself and can be maintained independently. MELT is n

Re: "plugin"-ifying the MELT branch.

2009-06-16 Thread Joseph S. Myers
On Tue, 16 Jun 2009, Janis Johnson wrote: > Basile, people are saying that MELT no longer belongs in a branch of > the GCC repository because now that plug-ins are supported, MELT no > longer needs to modify GCC itself and can be maintained independently. > That does not mean that MELT cannot be a

Re: AVR C++ - how to move vtables into FLASH memory

2009-06-16 Thread Denis Chertykov
2009/6/16 Ian Lance Taylor : > Tomasz Francuz writes: > >> I would like to change gcc so AVR C++ port will use FLASH memory >> instead of SRAM to store virtual function pointers. Does anyone try to >> do it? I have no experience as gcc developer, so can you head me to >> appropriate files/literatu

Re: git mirror at gcc.gnu.org

2009-06-16 Thread Bernie Innocenti
Daniel Berlin wrote: > pre-globals-git and restrict-git were test branches from an old mostly > broken version. ;) > > They are dead and if someone wants to manually remove the refs, go for it. > No idea what oldmaster is. Done. >> And why have both >> "master" and "trunk" as heads? > > See "

Re: AVR C++ - how to move vtables into FLASH memory

2009-06-16 Thread Zoltán Kócsi
> This question would be more appropriate for the mailing list > gcc-h...@gcc.gnu.org than for g...@gcc.gnu.org. Please take any > followups to gcc-help. Thanks. > > Virtual tables will normally be placed in the .rodata section which > holds read-only data. All you should need to do it arrange

Re: Rationale for an old TRUNCATE patch

2009-06-16 Thread Adam Nemet
Ian Lance Taylor writes: > I agree that this patch looks wrong in todays compiler. There should be > no need to call TRULY_NOOP_TRUNCATION if you are in a TRUNCATE anyhow. Thanks. Do you think we can assume this for TRUNCATEs in general or only for MIPS-like TRUNCATEs? I can't think of why it w

gcc-4.4-20090616 is now available

2009-06-16 Thread gccadmin
Snapshot gcc-4.4-20090616 is now available on ftp://gcc.gnu.org/pub/gcc/snapshots/4.4-20090616/ and on various mirrors, see http://gcc.gnu.org/mirrors.html for details. This snapshot has been generated from the GCC 4.4 SVN branch with the following options: svn://gcc.gnu.org/svn/gcc/branches

Re: AVR C++ - how to move vtables into FLASH memory

2009-06-16 Thread Ian Lance Taylor
Zoltán Kócsi writes: > So it is indeed a valid compiler issue, not an incompetent user issue. > Probably an improvement request would be the best. Thanks for the details on the AVR. The question of gcc vs. gcc-help is not one of compiler issues vs. incompetent user issues. Many highly competen

Re: Rationale for an old TRUNCATE patch

2009-06-16 Thread Ian Lance Taylor
Adam Nemet writes: > Ian Lance Taylor writes: >> I agree that this patch looks wrong in todays compiler. There should be >> no need to call TRULY_NOOP_TRUNCATION if you are in a TRUNCATE anyhow. > > Thanks. > > Do you think we can assume this for TRUNCATEs in general or only for MIPS-like > TRUN

Re: Address mode offset spill

2009-06-16 Thread daniel tian
> > One thing you certainly need to do is set REG_ALLOC_ORDER so that r0 is > the last register allocated. > > You need to set TARGET_RTX_COSTS so that constants larger than 512 are > more expensive than registers. That should prevent the constant from > being propagated into the insn. Yeah. I 'v

Re: Rationale for an old TRUNCATE patch

2009-06-16 Thread Jeff Law
Adam Nemet wrote: I am trying to understand the checkin by Jeff Law from about 11 years ago: r19204 | law | 1998-04-14 01:04:21 -0700 (Tue, 14 Apr 1998) | 4 lines * combine.c (simplify_rtx, case TRUNCATE): Respect value of TRULY_NOOP_TRUNCATION. Index

Re: Rationale for an old TRUNCATE patch

2009-06-16 Thread Jeff Law
Ian Lance Taylor wrote: Adam Nemet writes: I am trying to understand the checkin by Jeff Law from about 11 years ago: r19204 | law | 1998-04-14 01:04:21 -0700 (Tue, 14 Apr 1998) | 4 lines * combine.c (simplify_rtx, case TRUNCATE): Respect value of TRULY_NO

gcc for i386-solaris doesn't expand builtin functions for atomic memory access

2009-06-16 Thread Lijuan Hai
Hi all, As we see from gcc doc, the builtins are intended to be compatible with those described in the Intel Itanium Processor-specific Application Binary Interface, section 7.4. Why did gcc for x86 miss expanding such built-ins, just generating a call to an external function? Is it on purpose or

Re: gcc for i386-solaris doesn't expand builtin functions for atomic memory access

2009-06-16 Thread Ian Lance Taylor
Lijuan Hai writes: > As we see from gcc doc, the builtins are intended to be compatible > with those described in the Intel Itanium Processor-specific > Application Binary Interface, section 7.4. Why did gcc for x86 miss > expanding such built-ins, just generating a call to an external > function

Re: [gnat] reuse of ASTs already constructed

2009-06-16 Thread Oliver Kellogg
I got my first main program built in multi-source mode running. The ALI file and debug-info generation isn't perfect yet; also I'm using raw gnat1 as gnatmake is not yet adapted to multi-source mode. Oliver gnat1_multi_demo.tgz Description: application/compressed-tar

genrecog: ran out of alphabet

2009-06-16 Thread DJ Delorie
genrecog uses strings to keep track of where it is, specifically, digits and letters. I've got an insn that writes to more than 26 registers. Would switching to something bigger than [A-Z] be difficult? Perhaps using Japanese letters instead of English? ;-)

Ping: New Toshiba Media Processor (mep-elf) port and maintainer

2009-06-16 Thread DJ Delorie
> Pending initial (technical) approval Ping? Still waiting for technical approval from a global maintainer. http://people.redhat.com/dj/mep/

Re: Rationale for an old TRUNCATE patch

2009-06-16 Thread Adam Nemet
Jeff Law writes: > Ian Lance Taylor wrote: > > Adam Nemet writes: > > > > > >> I am trying to understand the checkin by Jeff Law from about 11 years ago: > >> > >>r19204 | law | 1998-04-14 01:04:21 -0700 (Tue, 14 Apr 1998) | 4 lines > >> > >> > >>* combine.c (simplify_rt

Re: Rationale for an old TRUNCATE patch

2009-06-16 Thread Adam Nemet
Ian Lance Taylor writes: > truncate has a machine independent meaning. Yes, I guess with your definition below it does. It's interesting though that Jim had said the opposite in the excerpts posted by Jeff: And a later message from Jim: Truncate converts a value from a larger to a smaller