ONEWS revision 72562
172562SobrienNoteworthy changes in GCC after EGCS 1.1. 272562Sobrien----------------------------------------- 372562Sobrien 472562SobrienTarget specific NEWS 572562Sobrien 672562Sobrien RS6000/PowerPC: -mcpu=401 was added as an alias for -mcpu=403. -mcpu=e603e 772562Sobrien was added to do -mcpu=603e and -msoft-float. 872562Sobrien 972562SobrienNoteworthy changes in GCC for EGCS 1.1. 1072562Sobrien--------------------------------------- 1172562Sobrien 1272562SobrienThe compiler now implements global common subexpression elimination (gcse) as 1372562Sobrienwell as global constant/copy propagation. (link to gcse page). 1472562Sobrien 1572562SobrienMore major improvements have been made to the alias analysis code. A new 1672562Sobrienoption to allow front-ends to provide alias information to the optimizers 1772562Sobrienhas also been added (-fstrict-aliasing). -fstrict-aliasing is off by default 1872562Sobriennow, but will be enabled by default in the future. (link to alias page) 1972562Sobrien 2072562SobrienMajor changes continue in the exception handling support. This release 2172562Sobrienincludes some changes to reduce static overhead for exception handling. It 2272562Sobrienalso includes some major changes to the setjmp/longjmp based EH mechanism to 2372562Sobrienmake it less pessimistic. And finally, major infrastructure improvements 2472562Sobriento the dwarf2 EH mechanism have been made to make our EH support extensible. 2572562Sobrien 2672562SobrienWe have fixed the infamous security problems with temporary files. 2772562Sobrien 2872562SobrienThe "regmove" optimization pass has been nearly completely rewritten. It now 2972562Sobrienuses much more information about the target to determine profitability of 3072562Sobrientransformations. 3172562Sobrien 3272562SobrienThe compiler now recomputes register usage information immediately before 3372562Sobrienregister allocation. Previously such information was only not kept up to 3472562Sobriendate after instruction combination which led to poor register allocation 3572562Sobrienchoices by our priority based register allocator. 3672562Sobrien 3772562SobrienThe register reloading phase of the compiler has been improved to better 3872562Sobrienoptimize spill code. This primarily helps targets which generate lots of 3972562Sobrienspills (like the x86 ports and many register poor embedded ports). 4072562Sobrien 4172562SobrienA few changes in the heuristics used by the register allocator and scheduler 4272562Sobrienhave been made which can significantly improve performance for certain 4372562Sobrienapplications. 4472562Sobrien 4572562SobrienThe compiler's branch shortening algorithms have been significantly improved 4672562Sobriento work better on targets which align jump targets. 4772562Sobrien 4872562SobrienThe compiler now supports the "ADDRESSOF" optimization which can significantly 4972562Sobrienreduce the overhead for certain inline calls (and inline calls in general). 5072562Sobrien 5172562SobrienThe compiler now supports a code size optimization switch (-Os). When enabled 5272562Sobrienthe compiler will prefer optimizations which improve code size over those 5372562Sobrienwhich improve code speed. 5472562Sobrien 5572562SobrienThe compiler has been improved to completely eliminate library calls which 5672562Sobriencompute constant values. This is particularly useful on machines which 5772562Sobriendo not have integer mul/div or floating point support on-chip. 5872562Sobrien 5972562SobrienGCC now supports a "--help" option to print detailed help information. 6072562Sobrien 6172562Sobriencpplib has been greatly improved. It is probably useable for some sites now 6272562Sobrien(major missing feature is trigraphs). 6372562Sobrien 6472562SobrienMemory footprint for the compiler has been significantly reduced for certain 6572562Sobrienpathalogical cases. 6672562Sobrien 6772562SobrienBuild time improvements for targets which support lots of sched parameters 6872562Sobrien(alpha and mips primarily). 6972562Sobrien 7072562SobrienCompile time for certain programs using large constant initializers has been 7172562Sobrienimproved (effects glibc significantly). 7272562Sobrien 7372562SobrienPlus an incredible number of infrastructure changes, warning fixes, bugfixes 7472562Sobrienand local optimizations. 7572562Sobrien 7672562SobrienVarious improvements have been made to better support cross compilations. They 7772562Sobrienare still not easy, but they are improving. 7872562Sobrien 7972562SobrienTarget specific NEWS 8072562Sobrien 8172562Sobrien Sparc: Now includes V8 plus and V9 support, lots of tuning for Ultrasparcs 8272562Sobrien and uses the Haifa scheduler by default. 8372562Sobrien 8472562Sobrien Alpha: EV6 tuned, optimized expansion of memcpy/bzero. 8572562Sobrien 8672562Sobrien x86: Data in the static store is aligned per Intel recommendations. Jump 8772562Sobrien targets are aligned per Intel recommendations. Improved epilogue 8872562Sobrien sequences for Pentium chips. Backend improvements which should help 8972562Sobrien register allocation on all x86 variants. Support for PPro conditional 9072562Sobrien move instructions has been fixed and enabled. Random changes 9172562Sobrien throughout the port to make generated code more Pentium friendly. 9272562Sobrien Improved support for 64bit integer operations. 9372562Sobrien Unixware 7, a System V Release 5 target is now supported. 9472562Sobrien SCO OpenServer targets can support GAS. See gcc/INSTALL for details. 9572562Sobrien 9672562Sobrien RS6000/PowerPC: Includes AIX4.3 support as well as PowerPC64 support. 9772562Sobrien Haifa instruction scheduling is enabled by default now. 9872562Sobrien 9972562Sobrien MIPS: Multiply/Multiply-Add support has been largely rewritten to generate 10072562Sobrien more efficient code. Includes mips16 support. 10172562Sobrien 10272562Sobrien M68K: Various micro-optimizations and Coldfire fixes. 10372562Sobrien 10472562Sobrien M32r: Major improvements to this port. 10572562Sobrien 10672562Sobrien Arm: Includes Thumb and super interworking support. 10772562Sobrien 10872562SobrienEGCS includes all gcc2 changes up to and including the June 9, 1998 snapshot. 10972562Sobrien 11072562Sobrien 11172562SobrienNoteworthy changes in GCC version 2.8.1 11272562Sobrien--------------------------------------- 11372562Sobrien 11472562SobrienNumerous bugs have been fixed and some minor performance 11572562Sobrienimprovements (compilation speed) have been made. 11672562Sobrien 11772562SobrienNoteworthy changes in GCC version 2.8.0 11872562Sobrien--------------------------------------- 11972562Sobrien 12072562SobrienA major change in this release is the addition of a framework for 12172562Sobrienexception handling, currently used by C++. Many internal changes and 12272562Sobrienoptimization improvements have been made. These increase the 12372562Sobrienmaintainability and portability of GCC. GCC now uses autoconf to 12472562Sobriencompute many host parameters. 12572562Sobrien 12672562SobrienThe following lists changes that add new features or targets. 12772562Sobrien 12872562SobrienSee cp/NEWS for new features of C++ in this release. 12972562Sobrien 13072562SobrienNew tools and features: 13172562Sobrien 13272562Sobrien The Dwarf 2 debugging information format is supported on ELF systems, and 13372562Sobrien is the default for -ggdb where available. It can also be used for C++. 13472562Sobrien The Dwarf version 1 debugging format is also permitted for C++, but 13572562Sobrien does not work well. 13672562Sobrien 13772562Sobrien gcov.c is provided for test coverage analysis and branch profiling 13872562Sobrien analysis is also supported; see -fprofile-arcs, -ftest-coverage, 13972562Sobrien and -fbranch-probabilities. 14072562Sobrien 14172562Sobrien Support for the Checker memory checking tool. 14272562Sobrien 14372562Sobrien New switch, -fstack-check, to check for stack overflow on systems that 14472562Sobrien don't have such built into their ABI. 14572562Sobrien 14672562Sobrien New switches, -Wundef and -Wno-undef to warn if an undefined identifier 14772562Sobrien is evaluated in an #if directive. 14872562Sobrien 14972562Sobrien Options -Wall and -Wimplicit now cause GCC to warn about implicit int 15072562Sobrien in declarations (e.g. `register i;'), since the C Standard committee 15172562Sobrien has decided to disallow this in the next revision of the standard; 15272562Sobrien -Wimplicit-function-declarations and -Wimplicit-int are subsets of 15372562Sobrien this. 15472562Sobrien 15572562Sobrien Option -Wsign-compare causes GCC to warn about comparison of signed and 15672562Sobrien unsigned values. 15772562Sobrien 15872562Sobrien Add -dI option of cccp for cxref. 15972562Sobrien 16072562SobrienNew features in configuration, installation and specs file handling: 16172562Sobrien 16272562Sobrien New option --enable-c-cpplib to configure script. 16372562Sobrien 16472562Sobrien You can use --with-cpu on the configure command to specify the default 16572562Sobrien CPU that GCC should generate code for. 16672562Sobrien 16772562Sobrien The -specs=file switch allows you to override default specs used in 16872562Sobrien invoking programs like cc1, as, etc. 16972562Sobrien 17072562Sobrien Allow including one specs file from another and renaming a specs 17172562Sobrien variable. 17272562Sobrien 17372562Sobrien You can now relocate all GCC files with a single environment variable 17472562Sobrien or a registry entry under Windows 95 and Windows NT. 17572562Sobrien 17672562SobrienChanges in Objective-C: 17772562Sobrien 17872562Sobrien The Objective-C Runtime Library has been made thread-safe. 17972562Sobrien 18072562Sobrien The Objective-C Runtime Library contains an interface for creating 18172562Sobrien mutexes, condition mutexes, and threads; it requires a back-end 18272562Sobrien implementation for the specific platform and/or thread package. 18372562Sobrien Currently supported are DEC/OSF1, IRIX, Mach, OS/2, POSIX, PCThreads, 18472562Sobrien Solaris, and Windows32. The --enable-threads parameter can be used 18572562Sobrien when configuring GCC to enable and select a thread back-end. 18672562Sobrien 18772562Sobrien Objective-C is now configured as separate front-end language to GCC, 18872562Sobrien making it more convenient to conditionally build it. 18972562Sobrien 19072562Sobrien The internal structures of the Objective-C Runtime Library have 19172562Sobrien changed sufficiently to warrant a new version number; now version 8. 19272562Sobrien Programs compiled with an older version must be recompiled. 19372562Sobrien 19472562Sobrien The Objective-C Runtime Library can be built as a DLL on Windows 95 19572562Sobrien and Windows NT systems. 19672562Sobrien 19772562Sobrien The Objective-C Runtime Library implements +load. 19872562Sobrien 19972562SobrienThe following new targets are supported (see also list under each 20072562Sobrienindividual CPU below): 20172562Sobrien 20272562Sobrien Embedded target m32r-elf. 20372562Sobrien Embedded Hitachi Super-H using ELF. 20472562Sobrien RTEMS real-time system on various CPU targets. 20572562Sobrien ARC processor. 20672562Sobrien NEC V850 processor. 20772562Sobrien Matsushita MN10200 processor. 20872562Sobrien Matsushita MN10300 processor. 20972562Sobrien Sparc and PowerPC running on VxWorks. 21072562Sobrien Support both glibc versions 1 and 2 on Linux-based GNU systems. 21172562Sobrien 21272562SobrienNew features for DEC Alpha systems: 21372562Sobrien 21472562Sobrien Allow detailed specification of IEEE fp support: 21572562Sobrien -mieee, -mieee-with-inexact, and -mieee-conformant 21672562Sobrien -mfp-trap-mode=xxx, -mfp-round-mode=xxx, -mtrap-precision=xxx 21772562Sobrien -mcpu=xxx for CPU selection 21872562Sobrien Support scheduling parameters for EV5. 21972562Sobrien Add support for BWX, CIX, and MAX instruction set extensions. 22072562Sobrien Support Linux-based GNU systems. 22172562Sobrien Support VMS. 22272562Sobrien 22372562SobrienAdditional supported processors and systems for MIPS targets: 22472562Sobrien 22572562Sobrien MIPS4 instruction set. 22672562Sobrien R4100, R4300 and R5000 processors. 22772562Sobrien N32 and N64 ABI. 22872562Sobrien IRIX 6.2. 22972562Sobrien SNI SINIX. 23072562Sobrien 23172562SobrienNew features for Intel x86 family: 23272562Sobrien 23372562Sobrien Add scheduling parameters for Pentium and Pentium Pro. 23472562Sobrien Support stabs on Solaris-x86. 23572562Sobrien Intel x86 processors running the SCO OpenServer 5 family. 23672562Sobrien Intel x86 processors running DG/UX. 23772562Sobrien Intel x86 using Cygwin32 or Mingw32 on Windows 95 and Windows NT. 23872562Sobrien 23972562SobrienNew features for Motorola 68k family: 24072562Sobrien 24172562Sobrien Support for 68060 processor. 24272562Sobrien More consistent switches to specify processor. 24372562Sobrien Motorola 68k family running AUX. 24472562Sobrien 68040 running pSOS, ELF object files, DBX debugging. 24572562Sobrien Coldfire variant of Motorola m68k family. 24672562Sobrien 24772562SobrienNew features for the HP PA RISC: 24872562Sobrien 24972562Sobrien -mspace and -mno-space 25072562Sobrien -mlong-load-store and -mno-long-load-store 25172562Sobrien -mbig-switch -mno-big-switch 25272562Sobrien 25372562Sobrien GCC on the PA requires either gas-2.7 or the HP assembler; for best 25472562Sobrien results using GAS is highly recommended. GAS is required for -g and 25572562Sobrien exception handling support. 25672562Sobrien 25772562SobrienNew features for SPARC-based systems: 25872562Sobrien 25972562Sobrien The ultrasparc cpu. 26072562Sobrien The sparclet cpu, supporting only a.out file format. 26172562Sobrien Sparc running SunOS 4 with the GNU assembler. 26272562Sobrien Sparc running the Linux-based GNU system. 26372562Sobrien Embedded Sparc processors running the ELF object file format. 26472562Sobrien -mcpu=xxx 26572562Sobrien -mtune=xxx 26672562Sobrien -malign-loops=xxx 26772562Sobrien -malign-jumps=xxx 26872562Sobrien -malign-functions=xxx 26972562Sobrien -mimpure-text and -mno-impure-text 27072562Sobrien 27172562Sobrien Options -mno-v8 and -mno-sparclite are no longer supported on SPARC 27272562Sobrien targets. Options -mcypress, -mv8, -msupersparc, -msparclite, -mf930, 27372562Sobrien and -mf934 are deprecated and will be deleted in GCC 2.9. Use 27472562Sobrien -mcpu=xxx instead. 27572562Sobrien 27672562SobrienNew features for rs6000 and PowerPC systems: 27772562Sobrien 27872562Sobrien Solaris 2.51 running on PowerPC's. 27972562Sobrien The Linux-based GNU system running on PowerPC's. 28072562Sobrien -mcpu=604e,602,603e,620,801,823,mpc505,821,860,power2 28172562Sobrien -mtune=xxx 28272562Sobrien -mrelocatable-lib, -mno-relocatable-lib 28372562Sobrien -msim, -mmve, -memb 28472562Sobrien -mupdate, -mno-update 28572562Sobrien -mfused-madd, -mno-fused-madd 28672562Sobrien 28772562Sobrien -mregnames 28872562Sobrien -meabi 28972562Sobrien -mcall-linux, -mcall-solaris, -mcall-sysv-eabi, -mcall-sysv-noeabi 29072562Sobrien -msdata, -msdata=none, -msdata=default, -msdata=sysv, -msdata=eabi 29172562Sobrien -memb, -msim, -mmvme 29272562Sobrien -myellowknife, -mads 29372562Sobrien wchar_t is now of type long as per the ABI, not unsigned short. 29472562Sobrien -p/-pg support 29572562Sobrien -mcpu=403 now implies -mstrict-align. 29672562Sobrien Implement System V profiling. 29772562Sobrien 29872562Sobrien Aix 4.1 GCC targets now default to -mcpu=common so that programs 29972562Sobrien compiled can be moved between rs6000 and powerpc based systems. A 30072562Sobrien consequence of this is that -static won't work, and that some programs 30172562Sobrien may be slightly slower. 30272562Sobrien 30372562Sobrien You can select the default value to use for -mcpu=xxx on rs6000 and 30472562Sobrien powerpc targets by using the --with-cpu=xxx option when configuring the 30572562Sobrien compiler. In addition, a new options, -mtune=xxx was added that 30672562Sobrien selects the machine to schedule for but does not select the 30772562Sobrien architecture level. 30872562Sobrien 30972562Sobrien Directory names used for storing the multilib libraries on System V 31072562Sobrien and embedded PowerPC systems have been shortened to work with commands 31172562Sobrien like tar that have fixed limits on pathname size. 31272562Sobrien 31372562SobrienNew features for the Hitachi H8/300(H): 31472562Sobrien 31572562Sobrien -malign-300 31672562Sobrien -ms (for the Hitachi H8/S processor) 31772562Sobrien -mint32 31872562Sobrien 31972562SobrienNew features for the ARM: 32072562Sobrien 32172562Sobrien -march=xxx, -mtune=xxx, -mcpu=xxx 32272562Sobrien Support interworking with Thumb code. 32372562Sobrien ARM processor with a.out object format, COFF, or AOF assembler. 32472562Sobrien ARM on "semi-hosted" platform. 32572562Sobrien ARM running NetBSD. 32672562Sobrien ARM running the Linux-based GNU system. 32772562Sobrien 32872562SobrienNew feature for Solaris systems: 32972562Sobrien 33072562Sobrien GCC installation no longer makes a copy of system include files, 33172562Sobrien thus insulating GCC better from updates to the operating system. 33272562Sobrien 33372562Sobrien 33472562SobrienNoteworthy changes in GCC version 2.7.2 33572562Sobrien--------------------------------------- 33672562Sobrien 33772562SobrienA few bugs have been fixed (most notably the generation of an 33872562Sobrieninvalid assembler opcode on some RS/6000 systems). 33972562Sobrien 34072562SobrienNoteworthy changes in GCC version 2.7.1 34172562Sobrien--------------------------------------- 34272562Sobrien 34372562SobrienThis release fixes numerous bugs (mostly minor) in GCC 2.7.0, but 34472562Sobrienalso contains a few new features, mostly related to specific targets. 34572562Sobrien 34672562SobrienMajor changes have been made in code to support Windows NT. 34772562Sobrien 34872562SobrienThe following new targets are supported: 34972562Sobrien 35072562Sobrien 2.9 BSD on PDP-11 35172562Sobrien Linux on m68k 35272562Sobrien HP/UX version 10 on HP PA RISC (treated like version 9) 35372562Sobrien DEC Alpha running Windows NT 35472562Sobrien 35572562SobrienWhen parsing C, GCC now recognizes C++ style `//' comments unless you 35672562Sobrienspecify `-ansi' or `-traditional'. 35772562Sobrien 35872562SobrienThe PowerPC System V targets (powerpc-*-sysv, powerpc-*-eabi) now use the 35972562Sobriencalling sequence specified in the System V Application Binary Interface 36072562SobrienProcessor Supplement (PowerPC Processor ABI Supplement) rather than the calling 36172562Sobriensequence used in GCC version 2.7.0. That calling sequence was based on the AIX 36272562Sobriencalling sequence without function descriptors. To compile code for that older 36372562Sobriencalling sequence, either configure the compiler for powerpc-*-eabiaix or use 36472562Sobrienthe -mcall-aix switch when compiling and linking. 36572562Sobrien 36672562SobrienNoteworthy changes in GCC version 2.7.0 36772562Sobrien--------------------------------------- 36872562Sobrien 36972562SobrienGCC now works better on systems that use ".obj" and ".exe" instead of 37072562Sobrien".o" and no extension. This involved changes to the driver program, 37172562Sobriengcc.c, to convert ".o" names to ".obj" and to GCC's Makefile to use 37272562Sobrien".obj" and ".exe" in filenames that are not targets. In order to 37372562Sobrienbuild GCC on such systems, you may need versions of GNU make and/or 37472562Sobriencompatible shells. At this point, this support is preliminary. 37572562Sobrien 37672562SobrienObject file extensions of ".obj" and executable file extensions of 37772562Sobrien".exe" are allowed when using appropriate version of GNU Make. 37872562Sobrien 37972562SobrienNumerous enhancements were made to the __attribute__ facility including 38072562Sobrienmore attributes and more places that support it. We now support the 38172562Sobrien"packed", "nocommon", "noreturn", "volatile", "const", "unused", 38272562Sobrien"transparent_union", "constructor", "destructor", "mode", "section", 38372562Sobrien"align", "format", "weak", and "alias" attributes. Each of these 38472562Sobriennames may also be specified with added underscores, e.g., "__packed__". 38572562Sobrien__attribute__ may now be applied to parameter definitions, function 38672562Sobriendefinitions, and structure, enum, and union definitions. 38772562Sobrien 38872562SobrienGCC now supports returning more structures in registers, as specified by 38972562Sobrienmany calling sequences (ABIs), such as on the HP PA RISC. 39072562Sobrien 39172562SobrienA new option '-fpack-struct' was added to automatically pack all structure 39272562Sobrienmembers together without holes. 39372562Sobrien 39472562SobrienThere is a new library (cpplib) and program (cppmain) that at some 39572562Sobrienpoint will replace cpp (aka cccp). To use cppmain as cpp now, pass 39672562Sobrienthe option CCCP=cppmain to make. The library is already used by the 39772562Sobrienfix-header program, which should speed up the fixproto script. 39872562Sobrien 39972562SobrienNew options for supported targets: 40072562Sobrien 40172562Sobrien GNU on many targets. 40272562Sobrien NetBSD on MIPS, m68k, VAX, and x86. 40372562Sobrien LynxOS on x86, m68k, Sparc, and RS/6000. 40472562Sobrien VxWorks on many targets. 40572562Sobrien 40672562Sobrien Windows/NT on x86 architecture. Initial support for Windows/NT on Alpha 40772562Sobrien (not fully working). 40872562Sobrien 40972562Sobrien Many embedded targets, specifically UDI on a29k, aout, coff, elf, 41072562Sobrien and vsta "operating systems" on m68k, m88k, mips, sparc, and x86. 41172562Sobrien 41272562SobrienAdditional support for x86 (i386, i486, and Pentium): 41372562Sobrien 41472562Sobrien Work with old and new linkers for Linux-based GNU systems, 41572562Sobrien supporting both a.out and ELF. 41672562Sobrien FreeBSD on x86. 41772562Sobrien Stdcall convention. 41872562Sobrien -malign-double, -mregparm=, -malign-loops= and -malign-jumps= switches. 41972562Sobrien On ISC systems, support -Xp like -posix. 42072562Sobrien 42172562SobrienAdditions for RS/6000: 42272562Sobrien 42372562Sobrien Instruction scheduling information for PowerPC 403. 42472562Sobrien AIX 4.1 on PowerPC. 42572562Sobrien -mstring and -mno-string. 42672562Sobrien -msoft-float and floating-point emulation included. 42772562Sobrien Preliminary support for PowerPC System V.4 with or without the GNU as. 42872562Sobrien Preliminary support for EABI. 42972562Sobrien Preliminary support for 64-bit systems. 43072562Sobrien Both big and little endian systems. 43172562Sobrien 43272562SobrienNew features for MIPS-based systems: 43372562Sobrien 43472562Sobrien r4650. 43572562Sobrien mips4 and R8000. 43672562Sobrien Irix 6.0. 43772562Sobrien 64-bit ABI. 43872562Sobrien Allow dollar signs in labels on SGI/Irix 5.x. 43972562Sobrien 44072562SobrienNew support for HP PA RISC: 44172562Sobrien 44272562Sobrien Generation of PIC (requires binutils-2.5.2.u6 or later). 44372562Sobrien HP-UX version 9 on HP PA RISC (dynamically links even with -g). 44472562Sobrien Processor variants for HP PA RISC: 700, 7100, and 7100LC. 44572562Sobrien Automatic generation of long calls when needed. 44672562Sobrien -mfast-indirect-calls for kernels and static binaries. 44772562Sobrien 44872562Sobrien The called routine now copies arguments passed by invisible reference, 44972562Sobrien as required by the calling standard. 45072562Sobrien 45172562SobrienOther new miscellaneous target-specific support: 45272562Sobrien 45372562Sobrien -mno-multm on a29k. 45472562Sobrien -mold-align for i960. 45572562Sobrien Configuration for "semi-hosted" ARM. 45672562Sobrien -momit-leaf-frame-pointer for M88k. 45772562Sobrien SH3 variant of Hitachi Super-H and support both big and little endian. 45872562Sobrien 45972562SobrienChanges to Objective-C: 46072562Sobrien 46172562Sobrien Bare-bones implementation of NXConstantString has been added, 46272562Sobrien which is invoked by the @"string" directive. 46372562Sobrien 46472562Sobrien Class * has been changed to Class to conform to the NextSTEP and 46572562Sobrien OpenStep runtime. 46672562Sobrien 46772562Sobrien Enhancements to make dynamic loading easier. 46872562Sobrien 46972562Sobrien The module version number has been updated to Version 7, thus existing 47072562Sobrien code will need to be recompiled to use the current run-time library. 47172562Sobrien 47272562SobrienGCC now supports the ISO Normative Addendum 1 to the C Standard. 47372562SobrienAs a result: 47472562Sobrien 47572562Sobrien The header <iso646.h> defines macros for C programs written 47672562Sobrien in national variants of ISO 646. 47772562Sobrien 47872562Sobrien The following digraph tokens are supported: 47972562Sobrien <: :> <% %> %: %:%: 48072562Sobrien These behave like the following, respectively: 48172562Sobrien [ ] { } # ## 48272562Sobrien 48372562Sobrien Digraph tokens are supported unless you specify the `-traditional' 48472562Sobrien option; you do not need to specify `-ansi' or `-trigraphs'. Except 48572562Sobrien for contrived and unlikely examples involving preprocessor 48672562Sobrien stringizing, digraph interpretation doesn't change the meaning of 48772562Sobrien programs; this is unlike trigraph interpretation, which changes the 48872562Sobrien meanings of relatively common strings. 48972562Sobrien 49072562Sobrien The macro __STDC_VERSION__ has the value 199409L. 49172562Sobrien 49272562Sobrien As usual, for full conformance to the standard, you also need a 49372562Sobrien C library that conforms. 49472562Sobrien 49572562SobrienThe following lists changes that have been made to g++. If some 49672562Sobrienfeatures mentioned below sound unfamiliar, you will probably want to 49772562Sobrienlook at the recently-released public review copy of the C++ Working 49872562SobrienPaper. For PostScript and PDF (Adobe Acrobat) versions, see the 49972562Sobrienarchive at ftp://research.att.com/dist/stdc++/WP. For HTML and ASCII 50072562Sobrienversions, see ftp://ftp.cygnus.com/pub/g++. On the web, see 50172562Sobrienhttp://www.cygnus.com/~mrs/wp-draft. 50272562Sobrien 50372562SobrienThe scope of variables declared in the for-init-statement has been changed 50472562Sobriento conform to http://www.cygnus.com/~mrs/wp-draft/stmt.html#stmt.for; as a 50572562Sobrienresult, packages such as groff 1.09 will not compile unless you specify the 50672562Sobrien-fno-for-scope flag. PLEASE DO NOT REPORT THIS AS A BUG; this is a change 50772562Sobrienmandated by the C++ standardization committee. 50872562Sobrien 50972562SobrienBinary incompatibilities: 51072562Sobrien 51172562Sobrien The builtin 'bool' type is now the size of a machine word on RISC targets, 51272562Sobrien for code efficiency; it remains one byte long on CISC targets. 51372562Sobrien 51472562Sobrien Code that does not use #pragma interface/implementation will most 51572562Sobrien likely shrink dramatically, as g++ now only emits the vtable for a 51672562Sobrien class in the translation unit where its first non-inline, non-abstract 51772562Sobrien virtual function is defined. 51872562Sobrien 51972562Sobrien Classes that do not define the copy constructor will sometimes be 52072562Sobrien passed and returned in registers. This may illuminate latent bugs in 52172562Sobrien your code. 52272562Sobrien 52372562SobrienSupport for automatic template instantiation has *NOT* been added, due 52472562Sobriento a disagreement over design philosophies. 52572562Sobrien 52672562SobrienSupport for exception handling has been improved; more targets are now 52772562Sobriensupported, and throws will use the RTTI mechanism to match against the 52872562Sobriencatch parameter type. Optimization is NOT SUPPORTED with 52972562Sobrien-fhandle-exceptions; no need to report this as a bug. 53072562Sobrien 53172562SobrienSupport for Run-Time Type Identification has been added with -frtti. 53272562SobrienThis support is still in alpha; one major restriction is that any file 53372562Sobriencompiled with -frtti must include <typeinfo.h>. 53472562Sobrien 53572562SobrienPreliminary support for namespaces has been added. This support is far 53672562Sobrienfrom complete, and probably not useful. 53772562Sobrien 53872562SobrienSynthesis of compiler-generated constructors, destructors and 53972562Sobrienassignment operators is now deferred until the functions are used. 54072562Sobrien 54172562SobrienThe parsing of expressions such as `a ? b : c = 1' has changed from 54272562Sobrien`(a ? b : c) = 1' to `a : b ? (c = 1)'. 54372562Sobrien 54472562SobrienThe code generated for testing conditions, especially those using || 54572562Sobrienand &&, is now more efficient. 54672562Sobrien 54772562SobrienThe operator keywords and, and_eq, bitand, bitor, compl, not, not_eq, 54872562Sobrienor, or_eq, xor and xor_eq are now supported. Use -ansi or 54972562Sobrien-foperator-names to enable them. 55072562Sobrien 55172562SobrienThe 'explicit' keyword is now supported. 'explicit' is used to mark 55272562Sobrienconstructors and type conversion operators that should not be used 55372562Sobrienimplicitly. 55472562Sobrien 55572562Sobrieng++ now accepts the typename keyword, though it currently has no 55672562Sobriensemantics; it can be a no-op in the current template implementation. 55772562SobrienYou may want to start using it in your code, however, since the 55872562Sobrienpending rewrite of the template implementation to compile STL properly 55972562Sobrien(perhaps for 2.8.0, perhaps not) will require you to use it as 56072562Sobrienindicated by the current draft. 56172562Sobrien 56272562SobrienHandling of user-defined type conversion has been overhauled so that 56372562Sobrientype conversion operators are now found and used properly in 56472562Sobrienexpressions and function calls. 56572562Sobrien 56672562Sobrien-fno-strict-prototype now only applies to function declarations with 56772562Sobrien"C" linkage. 56872562Sobrien 56972562Sobrieng++ now warns about 'if (x=0)' with -Wparentheses or -Wall. 57072562Sobrien 57172562Sobrien#pragma weak and #pragma pack are supported on System V R4 targets, as 57272562Sobrienare various other target-specific #pragmas supported by gcc. 57372562Sobrien 57472562Sobriennew and delete of const types is now allowed (with no additional 57572562Sobriensemantics). 57672562Sobrien 57772562SobrienExplicit instantiation of template methods is now supported. Also, 57872562Sobrien'inline template class foo<int>;' can be used to emit only the vtable 57972562Sobrienfor a template class. 58072562Sobrien 58172562SobrienWith -fcheck-new, g++ will check the return value of all calls to 58272562Sobrienoperator new, and not attempt to modify a returned null pointer. 58372562Sobrien 58472562SobrienThe template instantiation code now handles more conversions when 58572562Sobrienpassing to a parameter that does not depend on template arguments. 58672562SobrienThis means that code like 'string s; cout << s;' now works. 58772562Sobrien 58872562SobrienInvalid jumps in a switch statement past declarations that require 58972562Sobrieninitializations are now caught. 59072562Sobrien 59172562SobrienFunctions declared 'extern inline' now have the same linkage semantics 59272562Sobrienas inline member functions. On supported targets, where previously 59372562Sobrienthese functions (and vtables, and template instantiations) would have 59472562Sobrienbeen defined statically, they will now be defined as weak symbols so 59572562Sobrienthat only one out-of-line definition is used. 59672562Sobrien 59772562Sobriencollect2 now demangles linker output, and c++filt has become part of 59872562Sobrienthe gcc distribution. 59972562Sobrien 60072562SobrienNoteworthy changes in GCC version 2.6.3: 60172562Sobrien 60272562SobrienA few more bugs have been fixed. 60372562Sobrien 60472562SobrienNoteworthy changes in GCC version 2.6.2: 60572562Sobrien 60672562SobrienA few bugs have been fixed. 60772562Sobrien 60872562SobrienNames of attributes can now be preceded and followed by double underscores. 60972562Sobrien 61072562SobrienNoteworthy changes in GCC version 2.6.1: 61172562Sobrien 61272562SobrienNumerous (mostly minor) bugs have been fixed. 61372562Sobrien 61472562SobrienThe following new configurations are supported: 61572562Sobrien 61672562Sobrien GNU on x86 (instead of treating it like MACH) 61772562Sobrien NetBSD on Sparc and Motorola 68k 61872562Sobrien AIX 4.1 on RS/6000 and PowerPC systems 61972562Sobrien Sequent DYNIX/ptx 1.x and 2.x. 62072562Sobrien Both COFF and ELF configurations on AViiON without using /bin/gcc 62172562Sobrien Windows/NT on x86 architecture; preliminary 62272562Sobrien AT&T DSP1610 digital signal processor chips 62372562Sobrien i960 systems on bare boards using COFF 62472562Sobrien PDP11; target only and not extensively tested 62572562Sobrien 62672562SobrienThe -pg option is now supported for Alpha under OSF/1 V3.0 or later. 62772562Sobrien 62872562SobrienFiles with an extension of ".c++" are treated as C++ code. 62972562Sobrien 63072562SobrienThe -Xlinker and -Wl arguments are now passed to the linker in the 63172562Sobrienposition they were specified on the command line. This makes it 63272562Sobrienpossible, for example, to pass flags to the linker about specific 63372562Sobrienobject files. 63472562Sobrien 63572562SobrienThe use of positional arguments to the configure script is no longer 63672562Sobrienrecommended. Use --target= to specify the target; see the GCC manual. 63772562Sobrien 63872562SobrienThe 386 now supports two new switches: -mreg-alloc=<string> changes 63972562Sobrienthe default register allocation order used by the compiler, and 64072562Sobrien-mno-wide-multiply disables the use of the mul/imul instructions that 64172562Sobrienproduce 64 bit results in EAX:EDX from 32 bit operands to do long long 64272562Sobrienmultiplies and 32-bit division by constants. 64372562Sobrien 64472562SobrienNoteworthy changes in GCC version 2.6.0: 64572562Sobrien 64672562SobrienNumerous bugs have been fixed, in the C and C++ front-ends, as 64772562Sobrienwell as in the common compiler code. 64872562Sobrien 64972562SobrienThis release includes the C, Objective-C, and C++ compilers. However, 65072562Sobrienwe have moved the files for the C++ compiler (G++) files to a 65172562Sobriensubdirectory, cp. Subsequent releases of GCC will split these files 65272562Sobriento a separate TAR file. 65372562Sobrien 65472562SobrienThe G++ team has been tracking the development of the ANSI standard for C++. 65572562SobrienHere are some new features added from the latest working paper: 65672562Sobrien 65772562Sobrien * built-in boolean type 'bool', with constants 'true' and 'false'. 65872562Sobrien * array new and delete (operator new [] and delete []). 65972562Sobrien * WP-conforming lifetime of temporaries. 66072562Sobrien * explicit instantiation of templates (template class A<int>;), 66172562Sobrien along with an option (-fno-implicit-templates) to disable emission 66272562Sobrien of implicitly instantiated templates, obsoletes -fexternal-templates. 66372562Sobrien * static member constants (static const int foo = 4; within the 66472562Sobrien class declaration). 66572562Sobrien 66672562SobrienMany error messages have been improved to tell the user more about the 66772562Sobrienproblem. Conformance checking with -pedantic-errors has been 66872562Sobrienimproved. G++ now compiles Fresco. 66972562Sobrien 67072562SobrienThere is now an experimental implementation of virtual functions using 67172562Sobrienthunks instead of Cfront-style vtables, enabled with -fvtable-thunks. 67272562SobrienThis option also enables a heuristic which causes the compiler to only 67372562Sobrienemit the vtable in the translation unit where its first non-inline 67472562Sobrienvirtual function is defined; using this option and 67572562Sobrien-fno-implicit-templates, users should be able to avoid #pragma 67672562Sobrieninterface/implementation altogether. 67772562Sobrien 67872562SobrienSignatures have been added as a GNU C++ extension. Using the option 67972562Sobrien-fhandle-signatures, users are able to turn on recognition of 68072562Sobriensignatures. A short introduction on signatures is in the section 68172562Sobrien`Extension to the C++ Language' in the manual. 68272562Sobrien 68372562SobrienThe `g++' program is now a C program, rather than a shell script. 68472562Sobrien 68572562SobrienLots and lots and lots of bugs fixes, in nested types, access control, 68672562Sobrienpointers to member functions, the parser, templates, overload 68772562Sobrienresolution, etc, etc. 68872562Sobrien 68972562SobrienThere have been two major enhancements to the Objective-C compiler: 69072562Sobrien 69172562Sobrien1) Added portability. It now runs on Alpha, and some problems with 69272562Sobrien message forwarding have been addressed on other platforms. 69372562Sobrien 69472562Sobrien2) Selectors have been redefined to be pointers to structs like: 69572562Sobrien { void *sel_id, char *sel_types }, where the sel_id is the unique 69672562Sobrien identifier, the selector itself is no longer unique. 69772562Sobrien 69872562Sobrien Programmers should use the new function sel_eq to test selector 69972562Sobrien equivalence. 70072562Sobrien 70172562SobrienThe following major changes have been made to the base compiler and 70272562Sobrienmachine-specific files. 70372562Sobrien 70472562Sobrien- The MIL-STD-1750A is a new port, but still preliminary. 70572562Sobrien 70672562Sobrien- The h8/300h is now supported; both the h8/300 and h8/300h ports come 70772562Sobrien with 32 bit IEEE 754 software floating point support. 70872562Sobrien 70972562Sobrien- The 64-bit Sparc (v9) and 64-bit MIPS chips are supported. 71072562Sobrien 71172562Sobrien- NetBSD is supported on m68k, Intel x86, and pc523 systems and FreeBSD 71272562Sobrien on x86. 71372562Sobrien 71472562Sobrien- COFF is supported on x86, m68k, and Sparc systems running LynxOS. 71572562Sobrien 71672562Sobrien- 68K systems from Bull and Concurrent are supported and System V 71772562Sobrien Release 4 is supported on the Atari. 71872562Sobrien 71972562Sobrien- GCC supports GAS on the Motorola 3300 (sysV68) and debugging 72072562Sobrien (assuming GAS) on the Plexus 68K system. (However, GAS does not yet 72172562Sobrien work on those systems). 72272562Sobrien 72372562Sobrien- System V Release 4 is supported on MIPS (Tandem). 72472562Sobrien 72572562Sobrien- For DG/UX, an ELF configuration is now supported, and both the ELF 72672562Sobrien and BCS configurations support ELF and COFF object file formats. 72772562Sobrien 72872562Sobrien- OSF/1 V2.0 is supported on Alpha. 72972562Sobrien 73072562Sobrien- Function profiling is also supported on Alpha. 73172562Sobrien 73272562Sobrien- GAS and GDB is supported for Irix 5 (MIPS). 73372562Sobrien 73472562Sobrien- "common mode" (code that will run on both POWER and PowerPC 73572562Sobrien architectures) is now supported for the RS/6000 family; the 73672562Sobrien compiler knows about more PPC chips. 73772562Sobrien 73872562Sobrien- Both NeXTStep 2.1 and 3 are supported on 68k-based architectures. 73972562Sobrien 74072562Sobrien- On the AMD 29k, the -msoft-float is now supported, as well as 74172562Sobrien -mno-sum-in-toc for RS/6000, -mapp-regs and -mflat for Sparc, and 74272562Sobrien -membedded-pic for MIPS. 74372562Sobrien 74472562Sobrien- GCC can now convert division by integer constants into the equivalent 74572562Sobrien multiplication and shift operations when that is faster than the 74672562Sobrien division. 74772562Sobrien 74872562Sobrien- Two new warning options, -Wbad-function-cast and 74972562Sobrien -Wmissing-declarations have been added. 75072562Sobrien 75172562Sobrien- Configurations may now add machine-specific __attribute__ options on 75272562Sobrien type; many machines support the `section' attribute. 75372562Sobrien 75472562Sobrien- The -ffast-math flag permits some optimization that violate strict 75572562Sobrien IEEE rules, such as converting X * 0.0 to 0.0. 75672562Sobrien 75772562SobrienNoteworthy changes in GCC version 2.5.8: 75872562Sobrien 75972562SobrienThis release only fixes a few serious bugs. These include fixes for a 76072562Sobrienbug that prevented most programs from working on the RS/6000, a bug 76172562Sobrienthat caused invalid assembler code for programs with a `switch' 76272562Sobrienstatement on the NS32K, a G++ problem that caused undefined names in 76372562Sobriensome configurations, and several less serious problems, some of which 76472562Sobriencan affect most configuration. 76572562Sobrien 76672562SobrienNoteworthy change in GCC version 2.5.7: 76772562Sobrien 76872562SobrienThis release only fixes a few bugs, one of which was causing bootstrap 76972562Sobriencompare errors on some systems. 77072562Sobrien 77172562SobrienNoteworthy change in GCC version 2.5.6: 77272562Sobrien 77372562SobrienA few backend bugs have been fixed, some of which only occur on one 77472562Sobrienmachine. 77572562Sobrien 77672562SobrienThe C++ compiler in 2.5.6 includes: 77772562Sobrien 77872562Sobrien * fixes for some common crashes 77972562Sobrien * correct handling of nested types that are referenced as `foo::bar' 78072562Sobrien * spurious warnings about friends being declared static and never 78172562Sobrien defined should no longer appear 78272562Sobrien * enums that are local to a method in a class, or a class that's 78372562Sobrien local to a function, are now handled correctly. For example: 78472562Sobrien class foo { void bar () { enum { x, y } E; x; } }; 78572562Sobrien void bar () { class foo { enum { x, y } E; E baz; }; } 78672562Sobrien 78772562SobrienNoteworthy change in GCC version 2.5.5: 78872562Sobrien 78972562SobrienA large number of C++ bugs have been fixed. 79072562Sobrien 79172562SobrienThe fixproto script adds prototypes conditionally on __cplusplus. 79272562Sobrien 79372562SobrienNoteworthy change in GCC version 2.5.4: 79472562Sobrien 79572562SobrienA bug fix in passing of structure arguments for the HP-PA architecture 79672562Sobrienmakes code compiled with GCC 2.5.4 incompatible with code compiled 79772562Sobrienwith earlier versions (if it passes struct arguments of 33 to 64 bits, 79872562Sobrieninterspersed with other types of arguments). 79972562Sobrien 80072562SobrienNoteworthy change in gcc version 2.5.3: 80172562Sobrien 80272562SobrienThe method of "mangling" C++ function names has been changed. So you 80372562Sobrienmust recompile all C++ programs completely when you start using GCC 80472562Sobrien2.5. Also, GCC 2.5 requires libg++ version 2.5. Earlier libg++ 80572562Sobrienversions won't work with GCC 2.5. (This is generally true--GCC 80672562Sobrienversion M.N requires libg++ version M.N.) 80772562Sobrien 80872562SobrienNoteworthy GCC changes in version 2.5: 80972562Sobrien 81072562Sobrien* There is now support for the IBM 370 architecture as a target. 81172562SobrienCurrently the only operating system supported is MVS; GCC does not run 81272562Sobrienon MVS, so you must produce .s files using GCC as a cross compiler, 81372562Sobrienthen transfer them to MVS to assemble them. This port is not reliable 81472562Sobrienyet. 81572562Sobrien 81672562Sobrien* The Power PC is now supported. 81772562Sobrien 81872562Sobrien* The i860-based Paragon machine is now supported. 81972562Sobrien 82072562Sobrien* The Hitachi 3050 (an HP-PA machine) is now supported. 82172562Sobrien 82272562Sobrien* The variable __GNUC_MINOR__ holds the minor version number of GCC, as 82372562Sobrienan integer. For version 2.5.X, the value is 5. 82472562Sobrien 82572562Sobrien* In C, initializers for static and global variables are now processed 82672562Sobrienan element at a time, so that they don't need a lot of storage. 82772562Sobrien 82872562Sobrien* The C syntax for specifying which structure field comes next in an 82972562Sobrieninitializer is now `.FIELDNAME='. The corresponding syntax for 83072562Sobrienarray initializers is now `[INDEX]='. For example, 83172562Sobrien 83272562Sobrien char whitespace[256] 83372562Sobrien = { [' '] = 1, ['\t'] = 1, ['\n'] = 1 }; 83472562Sobrien 83572562SobrienThis was changed to accord with the syntax proposed by the Numerical 83672562SobrienC Extensions Group (NCEG). 83772562Sobrien 83872562Sobrien* Complex numbers are now supported in C. Use the keyword __complex__ 83972562Sobriento declare complex data types. See the manual for details. 84072562Sobrien 84172562Sobrien* GCC now supports `long double' meaningfully on the Sparc (128-bit 84272562Sobrienfloating point) and on the 386 (96-bit floating point). The Sparc 84372562Sobriensupport is enabled on Solaris 2.x because earlier system versions 84472562Sobrien(SunOS 4) have bugs in the emulation. 84572562Sobrien 84672562Sobrien* All targets now have assertions for cpu, machine and system. So you 84772562Sobriencan now use assertions to distinguish among all supported targets. 84872562Sobrien 84972562Sobrien* Nested functions in C may now be inline. Just declare them inline 85072562Sobrienin the usual way. 85172562Sobrien 85272562Sobrien* Packed structure members are now supported fully; it should be possible 85372562Sobriento access them on any supported target, no matter how little alignment 85472562Sobrienthey have. 85572562Sobrien 85672562Sobrien* To declare that a function does not return, you must now write 85772562Sobriensomething like this (works only in 2.5): 85872562Sobrien 85972562Sobrien void fatal () __attribute__ ((noreturn)); 86072562Sobrien 86172562Sobrienor like this (works in older versions too): 86272562Sobrien 86372562Sobrien typedef void voidfn (); 86472562Sobrien 86572562Sobrien volatile voidfn fatal; 86672562Sobrien 86772562SobrienIt used to be possible to do so by writing this: 86872562Sobrien 86972562Sobrien volatile void fatal (); 87072562Sobrien 87172562Sobrienbut it turns out that ANSI C requires that to mean something 87272562Sobrienelse (which is useless). 87372562Sobrien 87472562SobrienLikewise, to declare that a function is side-effect-free 87572562Sobrienso that calls may be deleted or combined, write 87672562Sobriensomething like this (works only in 2.5): 87772562Sobrien 87872562Sobrien int computation () __attribute__ ((const)); 87972562Sobrien 88072562Sobrienor like this (works in older versions too): 88172562Sobrien 88272562Sobrien typedef int intfn (); 88372562Sobrien 88472562Sobrien const intfn computation; 88572562Sobrien 88672562Sobrien* The new option -iwithprefixbefore specifies a directory to add to 88772562Sobrienthe search path for include files in the same position where -I would 88872562Sobrienput it, but uses the specified prefix just like -iwithprefix. 88972562Sobrien 89072562Sobrien* Basic block profiling has been enhanced to record the function the 89172562Sobrienbasic block comes from, and if the module was compiled for debugging, 89272562Sobrienthe line number and filename. A default version of the basic block 89372562Sobriensupport module has been added to libgcc2 that appends the basic block 89472562Sobrieninformation to a text file 'bb.out'. Machine descriptions can now 89572562Sobrienoverride the basic block support module in the target macro file. 89672562Sobrien 89772562SobrienNew features in g++: 89872562Sobrien 89972562Sobrien* The new flag `-fansi-overloading' for C++. Use a newly implemented 90072562Sobrienscheme of argument matching for C++. It makes g++ more accurately 90172562Sobrienobey the rules set down in Chapter 13 of the Annotated C++ Reference 90272562SobrienManual (the ARM). This option will be turned on by default in a 90372562Sobrienfuture release. 90472562Sobrien 90572562Sobrien* The -finline-debug flag is now gone (it was never really used by the 90672562Sobrien compiler). 90772562Sobrien 90872562Sobrien* Recognizing the syntax for pointers to members, e.g., "foo::*bar", has been 90972562Sobrien dramatically improved. You should not get any syntax errors or incorrect 91072562Sobrien runtime results while using pointers to members correctly; if you do, it's 91172562Sobrien a definite bug. 91272562Sobrien 91372562Sobrien* Forward declaration of an enum is now flagged as an error. 91472562Sobrien 91572562Sobrien* Class-local typedefs are now working properly. 91672562Sobrien 91772562Sobrien* Nested class support has been significantly improved. The compiler 91872562Sobrien will now (in theory) support up to 240 nested classes before hitting 91972562Sobrien other system limits (like memory size). 92072562Sobrien 92172562Sobrien* There is a new C version of the `g++' driver, to replace the old 92272562Sobrien shell script. This should significantly improve the performance of 92372562Sobrien executing g++ on a system where a user's PATH environment variable 92472562Sobrien references many NFS-mounted filesystems. This driver also works 92572562Sobrien under MS-DOS and OS/2. 92672562Sobrien 92772562Sobrien* The ANSI committee working on the C++ standard has adopted a new 92872562Sobrien keyword `mutable'. This will allow you to make a specific member be 92972562Sobrien modifiable in an otherwise const class. 93072562Sobrien 93172562SobrienNoteworthy GCC changes in version 2.4.4: 93272562Sobrien 93372562Sobrien A crash building g++ on various hosts (including m68k) has been 93472562Sobrien fixed. Also the g++ compiler no longer reports incorrect 93572562Sobrien ambiguities in some situations where they do not exist, and 93672562Sobrien const template member functions are now being found properly. 93772562Sobrien 93872562SobrienNoteworthy GCC changes in version 2.4: 93972562Sobrien 94072562Sobrien* On each target, the default is now to return short structures 94172562Sobriencompatibly with the "usual" compiler on that target. 94272562Sobrien 94372562SobrienFor most targets, this means the default is to return all structures 94472562Sobrienin memory, like long structures, in whatever way is used on that 94572562Sobrientarget. Use -freg-struct-return to enable returning short structures 94672562Sobrien(and unions) in registers. 94772562Sobrien 94872562SobrienThis change means that newly compiled binaries are incompatible with 94972562Sobrienbinaries compiled with previous versions of GCC. 95072562Sobrien 95172562SobrienOn some targets, GCC is itself the usual compiler. On these targets, 95272562Sobrienthe default way to return short structures is still in registers. 95372562SobrienUse -fpcc-struct-return to tell GCC to return them in memory. 95472562Sobrien 95572562Sobrien* There is now a floating point emulator which can imitate the way all 95672562Sobriensupported target machines do floating point arithmetic. 95772562Sobrien 95872562SobrienThis makes it possible to have cross compilation to and from the VAX, 95972562Sobrienand between machines of different endianness. However, this works 96072562Sobrienonly when the target machine description is updated to use the new 96172562Sobrienfacilities, and not all have been updated. 96272562Sobrien 96372562SobrienThis also makes possible support for longer floating point types. 96472562SobrienGCC 2.4 supports extended format on the 68K if you use `long double', 96572562Sobrienfor targets that have a 68881. (When we have run time library 96672562Sobrienroutines for extended floating point, then `long double' will use 96772562Sobrienextended format on all 68K targets.) 96872562Sobrien 96972562SobrienWe expect to support extended floating point on the i386 and Sparc in 97072562Sobrienfuture versions. 97172562Sobrien 97272562Sobrien* Building GCC now automatically fixes the system's header files. 97372562SobrienThis should require no attention. 97472562Sobrien 97572562Sobrien* GCC now installs an unsigned data type as size_t when it fixes the 97672562Sobrienheader files (on all but a handful of old target machines). 97772562SobrienTherefore, the bug that size_t failed to be unsigned is fixed. 97872562Sobrien 97972562Sobrien* Building and installation are now completely separate. 98072562SobrienAll new files are constructed during the build process; 98172562Sobrieninstallation just copies them. 98272562Sobrien 98372562Sobrien* New targets supported: Clipper, Hitachi SH, Hitachi 8300, and Sparc 98472562SobrienLite. 98572562Sobrien 98672562Sobrien* A totally new and much better Objective C run time system is included. 98772562Sobrien 98872562Sobrien* Objective C supports many new features. Alas, I can't describe them 98972562Sobriensince I don't use that language; however, they are the same ones 99072562Sobriensupported in recent versions of the NeXT operating system. 99172562Sobrien 99272562Sobrien* The builtin functions __builtin_apply_args, __builtin_apply and 99372562Sobrien__builtin_return let you record the arguments and returned 99472562Sobrienvalue of a function without knowing their number or type. 99572562Sobrien 99672562Sobrien* The builtin string variables __FUNCTION__ and __PRETTY_FUNCTION__ 99772562Sobriengive the name of the function in the source, and a pretty-printed 99872562Sobrienversion of the name. The two are the same in C, but differ in C++. 99972562Sobrien 100072562Sobrien* Casts to union types do not yield lvalues. 100172562Sobrien 100272562Sobrien* ## before an empty rest argument discards the preceding sequence 100372562Sobrienof non-whitespace characters from the macro definition. 100472562Sobrien(This feature is subject to change.) 100572562Sobrien 100672562Sobrien 100772562SobrienNew features specific to C++: 100872562Sobrien 100972562Sobrien* The manual contains a new section ``Common Misunderstandings with 101072562SobrienGNU C++'' that C++ users should read. 101172562Sobrien 101272562Sobrien* #pragma interface and #pragma implementation let you use the same 101372562SobrienC++ source file for both interface and implementation. 101472562SobrienHowever, this mechanism is still in transition. 101572562Sobrien 101672562Sobrien* Named returned values let you avoid an extra constructor call 101772562Sobrienwhen a function result has a class type. 101872562Sobrien 101972562Sobrien* The C++ operators <? and >? yield min and max, respectively. 102072562Sobrien 102172562Sobrien* C++ gotos can exit a block safely even if the block has 102272562Sobrienaggregates that require destructors. 102372562Sobrien 102472562Sobrien* gcc defines the macro __GNUG__ when compiling C++ programs. 102572562Sobrien 102672562Sobrien* GNU C++ now correctly distinguishes between the prefix and postfix 102772562Sobrienforms of overloaded operator ++ and --. To avoid breaking old 102872562Sobriencode, if a class defines only the prefix form, the compiler 102972562Sobrienaccepts either ++obj or obj++, unless -pedantic is used. 103072562Sobrien 103172562Sobrien* If you are using version 2.3 of libg++, you need to rebuild it with 103272562Sobrien`make CC=gcc' to avoid mismatches in the definition of `size_t'. 103372562Sobrien 103472562SobrienNewly documented compiler options: 103572562Sobrien 103672562Sobrien-fnostartfiles 103772562Sobrien Omit the standard system startup files when linking. 103872562Sobrien 103972562Sobrien-fvolatile-global 104072562Sobrien Consider memory references to extern and global data items to 104172562Sobrien be volatile. 104272562Sobrien 104372562Sobrien-idirafter DIR 104472562Sobrien Add DIR to the second include path. 104572562Sobrien 104672562Sobrien-iprefix PREFIX 104772562Sobrien Specify PREFIX for later -iwithprefix options. 104872562Sobrien 104972562Sobrien-iwithprefix DIR 105072562Sobrien Add PREFIX/DIR to the second include path. 105172562Sobrien 105272562Sobrien-mv8 105372562Sobrien Emit Sparc v8 code (with integer multiply and divide). 105472562Sobrien-msparclite 105572562Sobrien Emit Sparclite code (roughly v7.5). 105672562Sobrien 105772562Sobrien-print-libgcc-file-name 105872562Sobrien Search for the libgcc.a file, print its absolute file name, and exit. 105972562Sobrien 106072562Sobrien-Woverloaded-virtual 106172562Sobrien Warn when a derived class function declaration may be an error 106272562Sobrien in defining a C++ virtual function. 106372562Sobrien 106472562Sobrien-Wtemplate-debugging 106572562Sobrien When using templates in a C++ program, warn if debugging is 106672562Sobrien not yet fully available. 106772562Sobrien 106872562Sobrien+eN 106972562Sobrien Control how C++ virtual function definitions are used 107072562Sobrien (like cfront 1.x). 107172562Sobrien 1072