Re: question about TARGET_MUST_PASS_IN_STACK

2009-06-03 Thread Ian Lance Taylor
DJ Delorie writes: > On xstormy16, when structures with variable-length arrays are passed > to functions (execute/20020412-1.c), it appears that they're passed by > reference (based on examining the stack), despite the port not > explicitly requesting that. > > This causes a mis-match in the va_a

Re: gcc --help for options which are not warnings or optimizations

2009-06-03 Thread Nick Clifton
Hi Ian, Hi Diego, > Diego Novillo wrote: --help=other? That works. :-) Actually, there already is a qualifier which will select -fstack-protector, I had just forgotten about it: % gcc --help=common | grep stack -Wstack-protector Warn when not issuing stack smashing protectio

Any comment about the replacement of gcc news?

2009-06-03 Thread Eric Fisher
Hello Sorry, I hope it's not an offensive or boring topic. Some of my friends asked me if it's true that gcc will be replaced by other compilers on a few OS and what is the problem. Any comment? Best wishes Eric Fisher

Using a umulhisi3

2009-06-03 Thread Michael Hope
Hi there. The architecture I'm working is a 32 bit, word based machine with a 16x16 -> 32 unsigned multiply. For some reason the combine stage is converting the umulhisi3 into a mulsi3 and I'm not sure how to track this down. The test code is part of an alpha blend: void blend(uint8_t* sb, uint

Re: Using a umulhisi3

2009-06-03 Thread Julian Brown
On Wed, 3 Jun 2009 21:39:34 +1200 Michael Hope wrote: > How does the combine stage work? It looks like it could get multiple > potential matches for a set of RTLs. Does it use some type of costing > function to pick between them? Can I tell combine that a umulhisi3 is > cheaper than a mulsi3?

Re: Enquiry

2009-06-03 Thread Vijay
Thanks for the response Mukti. I think the options could be: |-mlong-calls -mno-ep and ||-mno-prolog-function. Could please tell me how to sepcify these options in makefile? Because I use gmake (in Cygwin shell) Thanks, -Vijay | mukti jain wrote: Can you experiment with optionmization op

Re: Any comment about the replacement of gcc news?

2009-06-03 Thread Ben Elliston
On Wed, 2009-06-03 at 16:33 +0800, Eric Fisher wrote: > Sorry, I hope it's not an offensive or boring topic. No, just off-topic. This list is for developing gcc, not plotting our demise. Cheers, Ben

Restrict keyword doesn't work correctly in GCC 4.4

2009-06-03 Thread Bingfeng Mei
Hello, I noticed that the restrict doesn't work fully on 4.4.0 (used to work on our port based on 4.3 branch). The problem is that tree optimizer can do a lot of optimization regarding pointer, e.g., at -O3. The alias set property is not propagated accordingly. Is the following RTL expansion co

Re: Restrict keyword doesn't work correctly in GCC 4.4

2009-06-03 Thread Richard Guenther
On Wed, Jun 3, 2009 at 12:41 PM, Bingfeng Mei wrote: > Hello, > I noticed that the restrict doesn't work fully on 4.4.0 (used to work on >  our port based on 4.3 branch). The problem is that tree optimizer can do a > lot of optimization regarding pointer, e.g., at -O3. The alias set property > is

Auto-import problem

2009-06-03 Thread Piotr Wyderski
Trying to work-around PR40269 (which doesn't happen anymore on trunk, so you may close it) I've commented out the dllexport/dllimport section: #define BASE_DLLEXPORT /*__declspec(dllexport)*/ #define BASE_DLLIMPORT /*__declspec(dllimport)*/ Then the program compiled succ

RE: Restrict keyword doesn't work correctly in GCC 4.4

2009-06-03 Thread Bingfeng Mei
Richard, Yes, my original code does have restrict qualified decl: void foo(int byte, char *a, char *b){ int * restrict dest = (int *)a; int * restrict src = (int *)b; for(int i = 0; i < byte/8; i++){ *dest++ = *src++; } } The code I shown is produced by tree level compilation.

Re: Auto-import problem

2009-06-03 Thread Dave Korn
Piotr Wyderski wrote: > Trying to work-around PR40269 (which doesn't happen > anymore on trunk, so you may close it) I've commented > out the dllexport/dllimport section: > > #define BASE_DLLEXPORT /*__declspec(dllexport)*/ > #define BASE_DLLIMPORT /*__declspec(dllimport)

The Linux binutils 2.19.51.0.8 is released.

2009-06-03 Thread H.J. Lu
This is the beta release of binutils 2.19.51.0.8 for Linux, which is based on binutils 2009 0603 in CVS on sourceware.org plus various changes. It is purely for Linux. All relevant patches in patches have been applied to the source tree. You can take a look at patches/README to see what have been

Re: Restrict keyword doesn't work correctly in GCC 4.4

2009-06-03 Thread Richard Guenther
On Wed, Jun 3, 2009 at 1:02 PM, Bingfeng Mei wrote: > Richard, > Yes, my original code does have restrict qualified decl: > >  void foo(int byte, char *a, char *b){ >  int * restrict dest = (int *)a; >  int * restrict src = (int *)b; > >  for(int i = 0; i < byte/8; i++){ >    *dest++ = *src++; >  

RE: Restrict keyword doesn't work correctly in GCC 4.4

2009-06-03 Thread Bingfeng Mei
Richard, Thanks. I tried your patch and the -fno-tree-ter, and none works. The problem is that decl = find_base_decl (TREE_OPERAND (inner, 0)); <--- Cannot find the base declaration, so decl = 0 if (decl <-- won't be checked && POINTER_

Re: Restrict keyword doesn't work correctly in GCC 4.4

2009-06-03 Thread Richard Guenther
On Wed, Jun 3, 2009 at 5:34 PM, Bingfeng Mei wrote: > Richard, > Thanks. I tried your patch and the -fno-tree-ter, and none works. The problem > is that > >       decl = find_base_decl (TREE_OPERAND (inner, 0));  <--- Cannot find the > base declaration, so decl = 0 > >       if (decl            

From regno to pseudo?

2009-06-03 Thread Steven Bosscher
Hello, Is there a way to get the REG for a given regno? I am building a register renumbering map that is just a pair of unsigned int , but I can't figure out how to get the REG for new_regno without remembering a pointer to it myself. Is there an easier/better way? Ciao! Steven

Re: From regno to pseudo?

2009-06-03 Thread Adam Nemet
Steven Bosscher writes: > Is there a way to get the REG for a given regno? I am building a > register renumbering map that is just a pair of unsigned int > , but I can't figure out how to get the REG for > new_regno without remembering a pointer to it myself. Is there an > easier/better way? reg

Problem with init of structure bit fields

2009-06-03 Thread Stelian Pop
Hi, I'm doing a port of gcc 4.3.3 on a custom architecture and I'm having trouble when initializing the bit fields of a structure. The testcase is based on a modified gcc torture testcase, the natural registers are 16 bits, and long long is defined to be 64 bit wide: struct itmp { long long i

Re: Problem with init of structure bit fields

2009-06-03 Thread Stelian Pop
On Wed, Jun 03, 2009 at 07:49:29PM +0200, Stelian Pop wrote: > I'm doing a port of gcc 4.3.3 on a custom architecture and I'm having trouble > when initializing the bit fields of a structure. Ok, after further analysis, it looks like a genuine bug in gcc, in store_bit_field_1(): when a field is

Re: Problem with init of structure bit fields

2009-06-03 Thread Ian Lance Taylor
Stelian Pop writes: > On Wed, Jun 03, 2009 at 07:49:29PM +0200, Stelian Pop wrote: > >> I'm doing a port of gcc 4.3.3 on a custom architecture and I'm having trouble >> when initializing the bit fields of a structure. > > Ok, after further analysis, it looks like a genuine bug in gcc, > in store

Re: Problem with init of structure bit fields

2009-06-03 Thread Stelian Pop
On Wed, Jun 03, 2009 at 01:07:08PM -0700, Ian Lance Taylor wrote: > > - unsigned int wordnum = (backwards ? nwords - i - 1 : i); > > + unsigned int wordnum = (backwards > > + ? GET_MODE_SIZE(fieldmode) / UNITS_PER_WORD > > + - i - 1

[4.3] Invalid code or invalid optimisation?

2009-06-03 Thread Dave Korn
Good morning everyone, I have an interesting situation. In this bit of code below, extracted from a simple testcase, I have a singly-linked list: template class List { public: List() : head(__null) { } void insert (lis

Help with BLOCK vs BIND_EXPR trees?

2009-06-03 Thread Jerry Quinn
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 texi docs and c

LLVM as a gcc plugin?

2009-06-03 Thread Uros Bizjak
Hello! Some time ago, there was a discussion about integrating LLVM and GCC [1]. However, with plugin infrastructure in place, could LLVM be plugged into GCC as an additional optimization plugin? [1] http://gcc.gnu.org/ml/gcc/2005-11/msg00888.html Uros.

Re: LLVM as a gcc plugin?

2009-06-03 Thread Chris Lattner
On Jun 3, 2009, at 11:30 PM, Uros Bizjak wrote: Hello! Some time ago, there was a discussion about integrating LLVM and GCC [1]. However, with plugin infrastructure in place, could LLVM be plugged into GCC as an additional optimization plugin? [1] http://gcc.gnu.org/ml/gcc/2005-11/msg00888.ht

Re: LLVM as a gcc plugin?

2009-06-03 Thread Miles Bader
Chris Lattner writes: >> Some time ago, there was a discussion about integrating LLVM and GCC >> [1]. However, with plugin infrastructure in place, could LLVM be >> plugged into GCC as an additional optimization plugin? > > I'd love to see this, but I can't contribute to it directly. I think > th