Re: __builtin_expect for indirect function calls

2008-01-05 Thread Richard Guenther
On Jan 5, 2008 6:43 AM, Mark Mitchell <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] wrote:
>
> > Currently, the prototype for __builtin_expect is
> >
> > long __builtin_expect (long expression, long constant);
> >
> > Extending it to functions would change it to
> >
> > T __builtin_expect (T expression, T expected);
>
> Yes, it really makes more sense for __builtin_expect to be polymorphic
> in this way anyhow.  I consider it a design wart that it's defined in
> terms of "long".  (For example, this means you can't use it for "long
> long"!)
>
> > Rather than the above definition, we could choose not to inspect the
> > context and just say:
> > * T is the type of 'expression'
> > * 'expected' is allowed to be a non-constant
> >
> > In this case I think there would only be compatibility issues with
> > unusual uses of __builtin_expect, for example, if it was being used in a
> > function argument and its type effected overload resolution.
>
> I think this is the abstractly right approach.  However, you're right
> that there are backwards-compatibility issues.  Another issue is that on
> platforms where "long" and "int" do not have the same width, something like:
>
>   sizeof(__builtin_expect(1, 1))
>
> will change its value.  And, the current prototype is documented in the
> manual.
>
> What do people think?  Do we have the leeway to change this?  Or should
> we add __builtin_expect2?  Or add an -fno-polymorphic-builtin-expect?
> Or...?

I think we should simply make __builtin_expect polymorphic, but make sure
to promote integral arguments with rank less than long to long.

Richard.


changing gcc

2008-01-05 Thread amnon stanislavsky
Hello

Could you please direct me on how to change gcc so that it will translate
c/c++ files to an assembly language to a new instruction set that I am
building?

Thank you in advance
Amnon




Pilgerweg nach Assisi

2008-01-05 Thread info

Comment=Warum ein Pilgerweg in Italien?
 
Der heilige Franz und der heilige Antonius, der friedfertige 
Gründer und der gelehrte Apostel („meo episcopus“ = mein Bischof) 
des Franziskanerordens, sind zwei unvergleichliche Figuren, die 
einen beständigen Motor angezündet haben einer demütigen und 
schlichten  Geisteshaltung, der eine unversiegbare Quelle ist für 
alle, die an einer existenziellen Dürre leiden.

Entsprechend diesen Voraussetzungen entsteht die Notwendigkeit, 
einen Pilgerweg anzubieten, der die neue geistige Anforderung 
erfüllt, der, anders als in der Vergangenheit, eine Suche nach 
„Bewegung“ ist, wo der Pilger vor allem Ur-Erfahrungen suchen 
will, um sich öffnen zu können für das Mitleiden mit jener 
„Liebe, die die Sonne und die andern Sterne bewegt“.
Auf den ersten Blick ist es das Ziel  des Pilger, nach Assisi zu 
gehen, aber in Wahrheit „geht man in sein eigenes  Innere“, um 
sich mit dem Göttlichen, das in Ihm verborgen ist, zu vereinigen. 
Der Pilgerweg nach Assisi ist kein neu konzipierter Weg, wie man 
denken könnte, sondern es ist die Verknüpfung von sehr vielen 
traditionsreichen Pilgerfahrten, die im lokalen Umkreis schon 
existieren ( siehe Assisi, La Verna, la Casella, Cerbaiolo, 
Montecasale, Montepaolo), verbunden mit eigenen Verehrungen, und 
die, wenn man sie in dieser Dimension  wiederbelebt, einen neuen 
Antrieb für das Erforschen des eigenen Innern geben werden und 
dabei das Wesentliche der Lehre des Franziskus neu aufblühen 
lassen. Und es sollen nicht nur die Steine dem Fremdling Seine 
Lehre bezeugen, sondern es soll sich auf dem Pilgerweg und in 
derselben Gemeinschaft auch die ursprüngliche franziskanische 
Bruderschaft erneuern.

Die Stadt Assisi wird sich erheben zu einem „Ort der universalen 
Übereinstimmung“ für die Menschen, die guten Willens sind, indem 
jeglicher Unterschied von Kultur und Glauben entsprechend den 
Grundprinzipien jeder wahren Religion überwunden wird

 Mit den besten Grüßen

Giordano
für
www.camminodiassisi.it




Re: changing gcc

2008-01-05 Thread Ian Lance Taylor
"amnon stanislavsky" <[EMAIL PROTECTED]> writes:

> Could you please direct me on how to change gcc so that it will translate
> c/c++ files to an assembly language to a new instruction set that I am
> building?

http://gcc.gnu.org/onlinedocs/gccint/

Notably the chapters "Machine Descriptions" and "Target Description
Macros and Functions".

Ian


MIPS/FORTRAN failures...

2008-01-05 Thread David Daney
The gfortran.dg/optional_dim_2.f90 test has been failing on mipsel-linux 
ever since it was added.


See:
http://gcc.gnu.org/ml/gcc-testresults/2008-01/msg00204.html
http://gcc.gnu.org/ml/gcc-testresults/2007-11/msg01522.html
http://gcc.gnu.org/ml/gcc-testresults/2007-11/msg01430.html


I don't really have time to look at it for the next few weeks.  But if 
another mips or fortran hacker were to fix it, we would have clean 
testsuite results for fortran on mips.


David Daney


Announcement: AspeCt-oriented C (ACC) version 0.8 !

2008-01-05 Thread mwgong
We are pleased to announce the release of AspeCt-oriented C (ACC) V 0.8.

The ACC 0.8 release includes several bug fixes and feature enhancements.

The highlights are:

1. result() pointcut can be used to modify the return value of a join point.

2. Support for accessing arguments' type/value and return type through the
"this" structure inside advice.

3. Match call/execution join points of a function which returns a function
pointer.

For more details and to download, please visit http://www.aspectc.net.

We appreciate feedback and support for AspeCt-oriented C.


Regards,

ACC Team

www.aspectc.net





"No such file error" when compiling powerpc-softfloat-linux-gnu libgfrotran

2008-01-05 Thread Xiaobo Yan
Hi

After I built powerpc-softfloat-linux-gnu gcc and gfortran compiler,
The c compiler works well and the gfortran show the error like this:
/bin/ld: cannot find -lgfortranbegin

I think it should work after install libgfortran, So I use the the
following configuration to build libgfortran which had been proved ok
when i built gcc and gfortran:

# *
#!/bin/sh

/home/yxb/gcc-4.0.0/configure --prefix=/home/yxb/install
--target=powerpc-softfloat-linux-gnu --disable-altivec
--with-float=soft --disable-nls --without-headers
--enable-languages=c,c++,f95 --with-cpu=405 --disable-multilib
--disable-threads --disable-shared --enable-static
--enable-__cxa-atexit --enable-clocale=gnu
--with-libs=/home/yxb/install/lib --enable-c99 --enable-long-long

make all-target-libgfortran install-target-libgfortran

# *

Then the first error i met was that cannot find stdlib.h string.h ctype.h

So I modified it into the following:


# *
#!/bin/sh

/home/yxb/gcc-4.0.0/configure --prefix=/home/yxb/install
--target=powerpc-softfloat-linux-gnu --disable-altivec
--with-float=soft --disable-nls --without-headers
--enable-languages=c,c++,f95 --with-cpu=405 --disable-multilib
--disable-threads --disable-shared --enable-static
--enable-__cxa-atexit --enable-clocale=gnu
--with-libs=/home/yxb/install/lib --enable-c99 --enable-long-long

make all-target-libgfortran install-target-libgfortran INCLUDES=-I/usr/include

# *

Now those header files can be found, but another error comes:

make[1]: Entering directory `/home/yxb/build/libiberty'
make[2]: Entering directory `/home/yxb/build/libiberty/testsuite'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/yxb/build/libiberty/testsuite'
make[1]: Leaving directory `/home/yxb/build/libiberty'
make[1]: Entering directory `/home/yxb/build/intl'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/home/yxb/build/intl'
make[1]: Entering directory `/home/yxb/build/build-i686-pc-linux-gnu/libiberty'
make[2]: Entering directory
`/home/yxb/build/build-i686-pc-linux-gnu/libiberty/testsuite'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory
`/home/yxb/build/build-i686-pc-linux-gnu/libiberty/testsuite'
make[1]: Leaving directory `/home/yxb/build/build-i686-pc-linux-gnu/libiberty'
make[1]: Entering directory
`/home/yxb/build/build-i686-pc-linux-gnu/fixincludes'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/home/yxb/build/build-i686-pc-linux-gnu/fixincludes'
make[1]: Entering directory `/home/yxb/build/libcpp'
test -f config.h || (rm -f stamp-h1 && make stamp-h1)
make[1]: Leaving directory `/home/yxb/build/libcpp'
make[1]: Entering directory `/home/yxb/build/fixincludes'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/home/yxb/build/fixincludes'
make[1]: Entering directory `/home/yxb/build/gcc'
make \
  CFLAGS="-g -O2 -W -Wall -Wwrite-strings -Wstrict-prototypes
-Wmissing-prototypes -pedantic -Wno-long-long -Wno-variadic-macros
-Wold-style-definition  " \
  CONFIG_H="config.h  auto-host.h
/home/yxb/gcc-4.0.0/gcc/../include/ansidecl.h" \
  MAKEOVERRIDES= \
  -f libgcc.mk all
make[2]: Entering directory `/home/yxb/build/gcc'
make GCC_FOR_TARGET="/home/yxb/build/gcc/xgcc -B/home/yxb/build/gcc/
-B/home/yxb/install/powerpc-softfloat-linux-gnu/bin/
-B/home/yxb/install/powerpc-softfloat-linux-gnu/lib/ -isystem
/home/yxb/install/powerpc-softfloat-linux-gnu/include -isystem
/home/yxb/install/powerpc-softfloat-linux-gnu/sys-include" \
  AR_FOR_TARGET="powerpc-softfloat-linux-gnu-ar" \
  AR_CREATE_FOR_TARGET="powerpc-softfloat-linux-gnu-ar  rc" \
  AR_EXTRACT_FOR_TARGET="powerpc-softfloat-linux-gnu-ar  x" \
  AR_FLAGS_FOR_TARGET="" \
  CC="gcc" CFLAGS="-g -O2 -W -Wall -Wwrite-strings -Wstrict-prototypes
-Wmissing-prototypes -pedantic -Wno-long-long -Wno-variadic-macros
-Wold-style-definition  " \
  BUILD_PREFIX="" \
  BUILD_PREFIX_1="loser-" \
  LANGUAGES="" \
  LIBGCC2_CFLAGS="-O2  -DIN_GCC -DCROSS_COMPILE   -W -Wall
-Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes
-Wold-style-definition  -isystem ./include  -fPIC -g  -DIN_LIBGCC2
-D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc "  \
  MULTILIB_CFLAGS="" T= crtbegin.o crtend.o crtbeginS.o crtendS.o
crtbeginT.o ecrti.o ecrtn.o ncrti.o ncrtn.o crtsavres.o
make[3]: Entering directory `/home/yxb/build/gcc'
make[3]: `crtend.o' is up to date.
make[3]: `crtbeginS.o' is up to date.
make[3]: `crtendS.o' is up to date.
make[3]: `crtbeginT.o' is up to date.
make[3]: `ecrti.o' is up to date.
make[3]: `ecrtn.o' is up to date.
make[3]: `ncrti.o' is up to date.
make[3]: `ncrtn.o' is up to date.
make[3]: `crtsavres.o' is up to date.
make[3]: Leaving directory `/home/yxb/build/gcc'
make[2]: Leaving directo