Mercurial > hg > CbC > CbC_gcc
annotate gcc/ONEWS @ 158:494b0b89df80 default tip
...
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 25 May 2020 18:13:55 +0900 |
parents | 04ced10e8804 |
children |
rev | line source |
---|---|
0 | 1 This file contains information about GCC releases up to GCC 2.8.1, and |
2 a tiny bit of information on EGCS. | |
3 | |
4 For details of changes in EGCS releases and GCC 2.95 and later releases, | |
5 see the release notes on the GCC web site or the file NEWS which contains | |
6 the most relevant parts of those release notes in text form. | |
7 | |
8 Changes in GCC for EGCS (that are not listed in the web release notes) | |
9 --------------------------------------------------------------------- | |
10 | |
11 The compiler now supports the "ADDRESSOF" optimization which can significantly | |
12 reduce the overhead for certain inline calls (and inline calls in general). | |
13 | |
14 Compile time for certain programs using large constant initializers has been | |
15 improved (affects glibc significantly). | |
16 | |
17 Various improvements have been made to better support cross compilations. They | |
18 are still not easy, but they are improving. | |
19 | |
20 Target-specific changes: | |
21 | |
22 M32r: Major improvements to this port. | |
23 | |
24 Arm: Includes Thumb and super interworking support. | |
25 | |
26 Noteworthy changes in GCC version 2.8.1 | |
27 --------------------------------------- | |
28 | |
29 Numerous bugs have been fixed and some minor performance | |
30 improvements (compilation speed) have been made. | |
31 | |
32 Noteworthy changes in GCC version 2.8.0 | |
33 --------------------------------------- | |
34 | |
35 A major change in this release is the addition of a framework for | |
36 exception handling, currently used by C++. Many internal changes and | |
37 optimization improvements have been made. These increase the | |
38 maintainability and portability of GCC. GCC now uses autoconf to | |
39 compute many host parameters. | |
40 | |
41 The following lists changes that add new features or targets. | |
42 | |
43 See cp/NEWS for new features of C++ in this release. | |
44 | |
45 New tools and features: | |
46 | |
47 The Dwarf 2 debugging information format is supported on ELF systems, and | |
48 is the default for -ggdb where available. It can also be used for C++. | |
49 The Dwarf version 1 debugging format is also permitted for C++, but | |
50 does not work well. | |
51 | |
52 gcov.c is provided for test coverage analysis and branch profiling | |
53 analysis is also supported; see -fprofile-arcs, -ftest-coverage, | |
54 and -fbranch-probabilities. | |
55 | |
56 Support for the Checker memory checking tool. | |
57 | |
58 New switch, -fstack-check, to check for stack overflow on systems that | |
59 don't have such built into their ABI. | |
60 | |
61 New switches, -Wundef and -Wno-undef to warn if an undefined identifier | |
62 is evaluated in an #if directive. | |
63 | |
64 Options -Wall and -Wimplicit now cause GCC to warn about implicit int | |
65 in declarations (e.g. `register i;'), since the C Standard committee | |
66 has decided to disallow this in the next revision of the standard; | |
67 -Wimplicit-function-declarations and -Wimplicit-int are subsets of | |
68 this. | |
69 | |
70 Option -Wsign-compare causes GCC to warn about comparison of signed and | |
71 unsigned values. | |
72 | |
73 Add -dI option of cccp for cxref. | |
74 | |
75 New features in configuration, installation and specs file handling: | |
76 | |
77 New option --enable-c-cpplib to configure script. | |
78 | |
79 You can use --with-cpu on the configure command to specify the default | |
80 CPU that GCC should generate code for. | |
81 | |
82 The -specs=file switch allows you to override default specs used in | |
83 invoking programs like cc1, as, etc. | |
84 | |
85 Allow including one specs file from another and renaming a specs | |
86 variable. | |
87 | |
88 You can now relocate all GCC files with a single environment variable | |
89 or a registry entry under Windows 95 and Windows NT. | |
90 | |
91 Changes in Objective-C: | |
92 | |
93 The Objective-C Runtime Library has been made thread-safe. | |
94 | |
95 The Objective-C Runtime Library contains an interface for creating | |
96 mutexes, condition mutexes, and threads; it requires a back-end | |
97 implementation for the specific platform and/or thread package. | |
98 Currently supported are DEC/OSF1, IRIX, Mach, OS/2, POSIX, PCThreads, | |
99 Solaris, and Windows32. The --enable-threads parameter can be used | |
100 when configuring GCC to enable and select a thread back-end. | |
101 | |
102 Objective-C is now configured as separate front-end language to GCC, | |
103 making it more convenient to conditionally build it. | |
104 | |
105 The internal structures of the Objective-C Runtime Library have | |
106 changed sufficiently to warrant a new version number; now version 8. | |
107 Programs compiled with an older version must be recompiled. | |
108 | |
109 The Objective-C Runtime Library can be built as a DLL on Windows 95 | |
110 and Windows NT systems. | |
111 | |
112 The Objective-C Runtime Library implements +load. | |
113 | |
114 The following new targets are supported (see also list under each | |
115 individual CPU below): | |
116 | |
117 Embedded target m32r-elf. | |
118 Embedded Hitachi Super-H using ELF. | |
119 RTEMS real-time system on various CPU targets. | |
120 ARC processor. | |
121 NEC V850 processor. | |
122 Matsushita MN10200 processor. | |
123 Matsushita MN10300 processor. | |
124 Sparc and PowerPC running on VxWorks. | |
125 Support both glibc versions 1 and 2 on Linux-based GNU systems. | |
126 | |
127 New features for DEC Alpha systems: | |
128 | |
129 Allow detailed specification of IEEE fp support: | |
130 -mieee, -mieee-with-inexact, and -mieee-conformant | |
131 -mfp-trap-mode=xxx, -mfp-round-mode=xxx, -mtrap-precision=xxx | |
132 -mcpu=xxx for CPU selection | |
133 Support scheduling parameters for EV5. | |
134 Add support for BWX, CIX, and MAX instruction set extensions. | |
135 Support Linux-based GNU systems. | |
136 Support VMS. | |
137 | |
138 Additional supported processors and systems for MIPS targets: | |
139 | |
140 MIPS4 instruction set. | |
141 R4100, R4300 and R5000 processors. | |
142 N32 and N64 ABI. | |
143 IRIX 6.2. | |
144 SNI SINIX. | |
145 | |
146 New features for Intel x86 family: | |
147 | |
148 Add scheduling parameters for Pentium and Pentium Pro. | |
149 Support stabs on Solaris-x86. | |
150 Intel x86 processors running the SCO OpenServer 5 family. | |
151 Intel x86 processors running DG/UX. | |
152 Intel x86 using Cygwin32 or Mingw32 on Windows 95 and Windows NT. | |
153 | |
154 New features for Motorola 68k family: | |
155 | |
156 Support for 68060 processor. | |
157 More consistent switches to specify processor. | |
158 Motorola 68k family running AUX. | |
159 68040 running pSOS, ELF object files, DBX debugging. | |
160 Coldfire variant of Motorola m68k family. | |
161 | |
162 New features for the HP PA RISC: | |
163 | |
164 -mspace and -mno-space | |
165 -mlong-load-store and -mno-long-load-store | |
166 -mbig-switch -mno-big-switch | |
167 | |
168 GCC on the PA requires either gas-2.7 or the HP assembler; for best | |
169 results using GAS is highly recommended. GAS is required for -g and | |
170 exception handling support. | |
171 | |
172 New features for SPARC-based systems: | |
173 | |
174 The ultrasparc cpu. | |
175 The sparclet cpu, supporting only a.out file format. | |
176 Sparc running SunOS 4 with the GNU assembler. | |
177 Sparc running the Linux-based GNU system. | |
178 Embedded Sparc processors running the ELF object file format. | |
179 -mcpu=xxx | |
180 -mtune=xxx | |
181 -malign-loops=xxx | |
182 -malign-jumps=xxx | |
183 -malign-functions=xxx | |
184 -mimpure-text and -mno-impure-text | |
185 | |
186 Options -mno-v8 and -mno-sparclite are no longer supported on SPARC | |
187 targets. Options -mcypress, -mv8, -msupersparc, -msparclite, -mf930, | |
188 and -mf934 are deprecated and will be deleted in GCC 2.9. Use | |
189 -mcpu=xxx instead. | |
190 | |
191 New features for rs6000 and PowerPC systems: | |
192 | |
193 Solaris 2.51 running on PowerPC's. | |
194 The Linux-based GNU system running on PowerPC's. | |
195 -mcpu=604e,602,603e,620,801,823,mpc505,821,860,power2 | |
196 -mtune=xxx | |
197 -mrelocatable-lib, -mno-relocatable-lib | |
198 -msim, -mmve, -memb | |
199 -mupdate, -mno-update | |
200 -mfused-madd, -mno-fused-madd | |
201 | |
202 -mregnames | |
203 -meabi | |
204 -mcall-linux, -mcall-solaris, -mcall-sysv-eabi, -mcall-sysv-noeabi | |
205 -msdata, -msdata=none, -msdata=default, -msdata=sysv, -msdata=eabi | |
206 -memb, -msim, -mmvme | |
207 -myellowknife, -mads | |
208 wchar_t is now of type long as per the ABI, not unsigned short. | |
209 -p/-pg support | |
210 -mcpu=403 now implies -mstrict-align. | |
211 Implement System V profiling. | |
212 | |
213 Aix 4.1 GCC targets now default to -mcpu=common so that programs | |
214 compiled can be moved between rs6000 and powerpc based systems. A | |
215 consequence of this is that -static won't work, and that some programs | |
216 may be slightly slower. | |
217 | |
218 You can select the default value to use for -mcpu=xxx on rs6000 and | |
219 powerpc targets by using the --with-cpu=xxx option when configuring the | |
220 compiler. In addition, a new options, -mtune=xxx was added that | |
221 selects the machine to schedule for but does not select the | |
222 architecture level. | |
223 | |
224 Directory names used for storing the multilib libraries on System V | |
225 and embedded PowerPC systems have been shortened to work with commands | |
226 like tar that have fixed limits on pathname size. | |
227 | |
228 New features for the Hitachi H8/300(H): | |
229 | |
230 -malign-300 | |
231 -ms (for the Hitachi H8/S processor) | |
232 -mint32 | |
233 | |
234 New features for the ARM: | |
235 | |
236 -march=xxx, -mtune=xxx, -mcpu=xxx | |
237 Support interworking with Thumb code. | |
238 ARM processor with a.out object format, COFF, or AOF assembler. | |
239 ARM on "semi-hosted" platform. | |
240 ARM running NetBSD. | |
241 ARM running the Linux-based GNU system. | |
242 | |
243 New feature for Solaris systems: | |
244 | |
245 GCC installation no longer makes a copy of system include files, | |
246 thus insulating GCC better from updates to the operating system. | |
247 | |
248 | |
249 Noteworthy changes in GCC version 2.7.2 | |
250 --------------------------------------- | |
251 | |
252 A few bugs have been fixed (most notably the generation of an | |
253 invalid assembler opcode on some RS/6000 systems). | |
254 | |
255 Noteworthy changes in GCC version 2.7.1 | |
256 --------------------------------------- | |
257 | |
258 This release fixes numerous bugs (mostly minor) in GCC 2.7.0, but | |
259 also contains a few new features, mostly related to specific targets. | |
260 | |
261 Major changes have been made in code to support Windows NT. | |
262 | |
263 The following new targets are supported: | |
264 | |
265 2.9 BSD on PDP-11 | |
266 Linux on m68k | |
267 HP/UX version 10 on HP PA RISC (treated like version 9) | |
268 DEC Alpha running Windows NT | |
269 | |
270 When parsing C, GCC now recognizes C++ style `//' comments unless you | |
271 specify `-ansi' or `-traditional'. | |
272 | |
273 The PowerPC System V targets (powerpc-*-sysv, powerpc-*-eabi) now use the | |
274 calling sequence specified in the System V Application Binary Interface | |
275 Processor Supplement (PowerPC Processor ABI Supplement) rather than the calling | |
276 sequence used in GCC version 2.7.0. That calling sequence was based on the AIX | |
277 calling sequence without function descriptors. To compile code for that older | |
278 calling sequence, either configure the compiler for powerpc-*-eabiaix or use | |
279 the -mcall-aix switch when compiling and linking. | |
280 | |
281 Noteworthy changes in GCC version 2.7.0 | |
282 --------------------------------------- | |
283 | |
284 GCC now works better on systems that use ".obj" and ".exe" instead of | |
285 ".o" and no extension. This involved changes to the driver program, | |
286 gcc.c, to convert ".o" names to ".obj" and to GCC's Makefile to use | |
287 ".obj" and ".exe" in filenames that are not targets. In order to | |
288 build GCC on such systems, you may need versions of GNU make and/or | |
289 compatible shells. At this point, this support is preliminary. | |
290 | |
291 Object file extensions of ".obj" and executable file extensions of | |
292 ".exe" are allowed when using appropriate version of GNU Make. | |
293 | |
294 Numerous enhancements were made to the __attribute__ facility including | |
295 more attributes and more places that support it. We now support the | |
296 "packed", "nocommon", "noreturn", "volatile", "const", "unused", | |
297 "transparent_union", "constructor", "destructor", "mode", "section", | |
298 "align", "format", "weak", and "alias" attributes. Each of these | |
299 names may also be specified with added underscores, e.g., "__packed__". | |
300 __attribute__ may now be applied to parameter definitions, function | |
301 definitions, and structure, enum, and union definitions. | |
302 | |
303 GCC now supports returning more structures in registers, as specified by | |
304 many calling sequences (ABIs), such as on the HP PA RISC. | |
305 | |
306 A new option '-fpack-struct' was added to automatically pack all structure | |
307 members together without holes. | |
308 | |
309 There is a new library (cpplib) and program (cppmain) that at some | |
310 point will replace cpp (aka cccp). To use cppmain as cpp now, pass | |
311 the option CCCP=cppmain to make. The library is already used by the | |
312 fix-header program, which should speed up the fixproto script. | |
313 | |
314 New options for supported targets: | |
315 | |
316 GNU on many targets. | |
317 NetBSD on MIPS, m68k, VAX, and x86. | |
318 LynxOS on x86, m68k, Sparc, and RS/6000. | |
319 VxWorks on many targets. | |
320 | |
321 Windows/NT on x86 architecture. Initial support for Windows/NT on Alpha | |
322 (not fully working). | |
323 | |
324 Many embedded targets, specifically UDI on a29k, aout, coff, elf, | |
325 and vsta "operating systems" on m68k, m88k, mips, sparc, and x86. | |
326 | |
327 Additional support for x86 (i386, i486, and Pentium): | |
328 | |
329 Work with old and new linkers for Linux-based GNU systems, | |
330 supporting both a.out and ELF. | |
331 FreeBSD on x86. | |
332 Stdcall convention. | |
333 -malign-double, -mregparm=, -malign-loops= and -malign-jumps= switches. | |
334 On ISC systems, support -Xp like -posix. | |
335 | |
336 Additions for RS/6000: | |
337 | |
338 Instruction scheduling information for PowerPC 403. | |
339 AIX 4.1 on PowerPC. | |
340 -mstring and -mno-string. | |
341 -msoft-float and floating-point emulation included. | |
342 Preliminary support for PowerPC System V.4 with or without the GNU as. | |
343 Preliminary support for EABI. | |
344 Preliminary support for 64-bit systems. | |
345 Both big and little endian systems. | |
346 | |
347 New features for MIPS-based systems: | |
348 | |
349 r4650. | |
350 mips4 and R8000. | |
351 Irix 6.0. | |
352 64-bit ABI. | |
353 Allow dollar signs in labels on SGI/Irix 5.x. | |
354 | |
355 New support for HP PA RISC: | |
356 | |
357 Generation of PIC (requires binutils-2.5.2.u6 or later). | |
358 HP-UX version 9 on HP PA RISC (dynamically links even with -g). | |
359 Processor variants for HP PA RISC: 700, 7100, and 7100LC. | |
360 Automatic generation of long calls when needed. | |
361 -mfast-indirect-calls for kernels and static binaries. | |
362 | |
363 The called routine now copies arguments passed by invisible reference, | |
364 as required by the calling standard. | |
365 | |
366 Other new miscellaneous target-specific support: | |
367 | |
368 -mno-multm on a29k. | |
369 -mold-align for i960. | |
370 Configuration for "semi-hosted" ARM. | |
371 -momit-leaf-frame-pointer for M88k. | |
372 SH3 variant of Hitachi Super-H and support both big and little endian. | |
373 | |
374 Changes to Objective-C: | |
375 | |
376 Bare-bones implementation of NXConstantString has been added, | |
377 which is invoked by the @"string" directive. | |
378 | |
379 Class * has been changed to Class to conform to the NextSTEP and | |
380 OpenStep runtime. | |
381 | |
382 Enhancements to make dynamic loading easier. | |
383 | |
384 The module version number has been updated to Version 7, thus existing | |
385 code will need to be recompiled to use the current run-time library. | |
386 | |
387 GCC now supports the ISO Normative Addendum 1 to the C Standard. | |
388 As a result: | |
389 | |
390 The header <iso646.h> defines macros for C programs written | |
391 in national variants of ISO 646. | |
392 | |
393 The following digraph tokens are supported: | |
394 <: :> <% %> %: %:%: | |
395 These behave like the following, respectively: | |
396 [ ] { } # ## | |
397 | |
398 Digraph tokens are supported unless you specify the `-traditional' | |
399 option; you do not need to specify `-ansi' or `-trigraphs'. Except | |
400 for contrived and unlikely examples involving preprocessor | |
401 stringizing, digraph interpretation doesn't change the meaning of | |
402 programs; this is unlike trigraph interpretation, which changes the | |
403 meanings of relatively common strings. | |
404 | |
405 The macro __STDC_VERSION__ has the value 199409L. | |
406 | |
407 As usual, for full conformance to the standard, you also need a | |
408 C library that conforms. | |
409 | |
410 The following lists changes that have been made to g++. If some | |
411 features mentioned below sound unfamiliar, you will probably want to | |
412 look at the recently-released public review copy of the C++ Working | |
413 Paper. For PostScript and PDF (Adobe Acrobat) versions, see the | |
414 archive at ftp://research.att.com/dist/stdc++/WP. For HTML and ASCII | |
415 versions, see ftp://ftp.cygnus.com/pub/g++. On the web, see | |
416 http://www.cygnus.com/~mrs/wp-draft. | |
417 | |
418 The scope of variables declared in the for-init-statement has been changed | |
419 to conform to http://www.cygnus.com/~mrs/wp-draft/stmt.html#stmt.for; as a | |
420 result, packages such as groff 1.09 will not compile unless you specify the | |
421 -fno-for-scope flag. PLEASE DO NOT REPORT THIS AS A BUG; this is a change | |
422 mandated by the C++ standardization committee. | |
423 | |
424 Binary incompatibilities: | |
425 | |
426 The builtin 'bool' type is now the size of a machine word on RISC targets, | |
427 for code efficiency; it remains one byte long on CISC targets. | |
428 | |
429 Code that does not use #pragma interface/implementation will most | |
430 likely shrink dramatically, as g++ now only emits the vtable for a | |
431 class in the translation unit where its first non-inline, non-abstract | |
432 virtual function is defined. | |
433 | |
434 Classes that do not define the copy constructor will sometimes be | |
435 passed and returned in registers. This may illuminate latent bugs in | |
436 your code. | |
437 | |
438 Support for automatic template instantiation has *NOT* been added, due | |
439 to a disagreement over design philosophies. | |
440 | |
441 Support for exception handling has been improved; more targets are now | |
442 supported, and throws will use the RTTI mechanism to match against the | |
443 catch parameter type. Optimization is NOT SUPPORTED with | |
444 -fhandle-exceptions; no need to report this as a bug. | |
445 | |
446 Support for Run-Time Type Identification has been added with -frtti. | |
447 This support is still in alpha; one major restriction is that any file | |
448 compiled with -frtti must include <typeinfo.h>. | |
449 | |
450 Preliminary support for namespaces has been added. This support is far | |
451 from complete, and probably not useful. | |
452 | |
453 Synthesis of compiler-generated constructors, destructors and | |
454 assignment operators is now deferred until the functions are used. | |
455 | |
456 The parsing of expressions such as `a ? b : c = 1' has changed from | |
457 `(a ? b : c) = 1' to `a : b ? (c = 1)'. | |
458 | |
459 The code generated for testing conditions, especially those using || | |
460 and &&, is now more efficient. | |
461 | |
462 The operator keywords and, and_eq, bitand, bitor, compl, not, not_eq, | |
463 or, or_eq, xor and xor_eq are now supported. Use -ansi or | |
464 -foperator-names to enable them. | |
465 | |
466 The 'explicit' keyword is now supported. 'explicit' is used to mark | |
467 constructors and type conversion operators that should not be used | |
468 implicitly. | |
469 | |
470 g++ now accepts the typename keyword, though it currently has no | |
471 semantics; it can be a no-op in the current template implementation. | |
472 You may want to start using it in your code, however, since the | |
473 pending rewrite of the template implementation to compile STL properly | |
474 (perhaps for 2.8.0, perhaps not) will require you to use it as | |
475 indicated by the current draft. | |
476 | |
477 Handling of user-defined type conversion has been overhauled so that | |
478 type conversion operators are now found and used properly in | |
479 expressions and function calls. | |
480 | |
481 -fno-strict-prototype now only applies to function declarations with | |
482 "C" linkage. | |
483 | |
484 g++ now warns about 'if (x=0)' with -Wparentheses or -Wall. | |
485 | |
486 #pragma weak and #pragma pack are supported on System V R4 targets, as | |
487 are various other target-specific #pragmas supported by gcc. | |
488 | |
489 new and delete of const types is now allowed (with no additional | |
490 semantics). | |
491 | |
492 Explicit instantiation of template methods is now supported. Also, | |
493 'inline template class foo<int>;' can be used to emit only the vtable | |
494 for a template class. | |
495 | |
496 With -fcheck-new, g++ will check the return value of all calls to | |
497 operator new, and not attempt to modify a returned null pointer. | |
498 | |
499 The template instantiation code now handles more conversions when | |
500 passing to a parameter that does not depend on template arguments. | |
501 This means that code like 'string s; cout << s;' now works. | |
502 | |
503 Invalid jumps in a switch statement past declarations that require | |
504 initializations are now caught. | |
505 | |
506 Functions declared 'extern inline' now have the same linkage semantics | |
507 as inline member functions. On supported targets, where previously | |
508 these functions (and vtables, and template instantiations) would have | |
509 been defined statically, they will now be defined as weak symbols so | |
510 that only one out-of-line definition is used. | |
511 | |
512 collect2 now demangles linker output, and c++filt has become part of | |
513 the gcc distribution. | |
514 | |
515 Noteworthy changes in GCC version 2.6.3: | |
516 | |
517 A few more bugs have been fixed. | |
518 | |
519 Noteworthy changes in GCC version 2.6.2: | |
520 | |
521 A few bugs have been fixed. | |
522 | |
523 Names of attributes can now be preceded and followed by double underscores. | |
524 | |
525 Noteworthy changes in GCC version 2.6.1: | |
526 | |
527 Numerous (mostly minor) bugs have been fixed. | |
528 | |
529 The following new configurations are supported: | |
530 | |
531 GNU on x86 (instead of treating it like MACH) | |
532 NetBSD on Sparc and Motorola 68k | |
533 AIX 4.1 on RS/6000 and PowerPC systems | |
534 Sequent DYNIX/ptx 1.x and 2.x. | |
535 Both COFF and ELF configurations on AViiON without using /bin/gcc | |
536 Windows/NT on x86 architecture; preliminary | |
537 AT&T DSP1610 digital signal processor chips | |
538 i960 systems on bare boards using COFF | |
539 PDP11; target only and not extensively tested | |
540 | |
541 The -pg option is now supported for Alpha under OSF/1 V3.0 or later. | |
542 | |
543 Files with an extension of ".c++" are treated as C++ code. | |
544 | |
545 The -Xlinker and -Wl arguments are now passed to the linker in the | |
546 position they were specified on the command line. This makes it | |
547 possible, for example, to pass flags to the linker about specific | |
548 object files. | |
549 | |
550 The use of positional arguments to the configure script is no longer | |
551 recommended. Use --target= to specify the target; see the GCC manual. | |
552 | |
553 The 386 now supports two new switches: -mreg-alloc=<string> changes | |
554 the default register allocation order used by the compiler, and | |
555 -mno-wide-multiply disables the use of the mul/imul instructions that | |
556 produce 64 bit results in EAX:EDX from 32 bit operands to do long long | |
557 multiplies and 32-bit division by constants. | |
558 | |
559 Noteworthy changes in GCC version 2.6.0: | |
560 | |
561 Numerous bugs have been fixed, in the C and C++ front-ends, as | |
562 well as in the common compiler code. | |
563 | |
564 This release includes the C, Objective-C, and C++ compilers. However, | |
565 we have moved the files for the C++ compiler (G++) files to a | |
566 subdirectory, cp. Subsequent releases of GCC will split these files | |
567 to a separate TAR file. | |
568 | |
569 The G++ team has been tracking the development of the ANSI standard for C++. | |
570 Here are some new features added from the latest working paper: | |
571 | |
572 * built-in boolean type 'bool', with constants 'true' and 'false'. | |
573 * array new and delete (operator new [] and delete []). | |
574 * WP-conforming lifetime of temporaries. | |
575 * explicit instantiation of templates (template class A<int>;), | |
576 along with an option (-fno-implicit-templates) to disable emission | |
577 of implicitly instantiated templates, obsoletes -fexternal-templates. | |
578 * static member constants (static const int foo = 4; within the | |
579 class declaration). | |
580 | |
581 Many error messages have been improved to tell the user more about the | |
582 problem. Conformance checking with -pedantic-errors has been | |
583 improved. G++ now compiles Fresco. | |
584 | |
585 There is now an experimental implementation of virtual functions using | |
586 thunks instead of Cfront-style vtables, enabled with -fvtable-thunks. | |
587 This option also enables a heuristic which causes the compiler to only | |
588 emit the vtable in the translation unit where its first non-inline | |
589 virtual function is defined; using this option and | |
590 -fno-implicit-templates, users should be able to avoid #pragma | |
591 interface/implementation altogether. | |
592 | |
593 Signatures have been added as a GNU C++ extension. Using the option | |
594 -fhandle-signatures, users are able to turn on recognition of | |
595 signatures. A short introduction on signatures is in the section | |
596 `Extension to the C++ Language' in the manual. | |
597 | |
598 The `g++' program is now a C program, rather than a shell script. | |
599 | |
600 Lots and lots and lots of bugs fixes, in nested types, access control, | |
601 pointers to member functions, the parser, templates, overload | |
602 resolution, etc, etc. | |
603 | |
604 There have been two major enhancements to the Objective-C compiler: | |
605 | |
606 1) Added portability. It now runs on Alpha, and some problems with | |
607 message forwarding have been addressed on other platforms. | |
608 | |
609 2) Selectors have been redefined to be pointers to structs like: | |
610 { void *sel_id, char *sel_types }, where the sel_id is the unique | |
611 identifier, the selector itself is no longer unique. | |
612 | |
613 Programmers should use the new function sel_eq to test selector | |
614 equivalence. | |
615 | |
616 The following major changes have been made to the base compiler and | |
617 machine-specific files. | |
618 | |
619 - The MIL-STD-1750A is a new port, but still preliminary. | |
620 | |
621 - The h8/300h is now supported; both the h8/300 and h8/300h ports come | |
622 with 32 bit IEEE 754 software floating point support. | |
623 | |
624 - The 64-bit Sparc (v9) and 64-bit MIPS chips are supported. | |
625 | |
626 - NetBSD is supported on m68k, Intel x86, and pc523 systems and FreeBSD | |
627 on x86. | |
628 | |
629 - COFF is supported on x86, m68k, and Sparc systems running LynxOS. | |
630 | |
631 - 68K systems from Bull and Concurrent are supported and System V | |
632 Release 4 is supported on the Atari. | |
633 | |
634 - GCC supports GAS on the Motorola 3300 (sysV68) and debugging | |
635 (assuming GAS) on the Plexus 68K system. (However, GAS does not yet | |
636 work on those systems). | |
637 | |
638 - System V Release 4 is supported on MIPS (Tandem). | |
639 | |
640 - For DG/UX, an ELF configuration is now supported, and both the ELF | |
641 and BCS configurations support ELF and COFF object file formats. | |
642 | |
643 - OSF/1 V2.0 is supported on Alpha. | |
644 | |
645 - Function profiling is also supported on Alpha. | |
646 | |
647 - GAS and GDB is supported for Irix 5 (MIPS). | |
648 | |
649 - "common mode" (code that will run on both POWER and PowerPC | |
650 architectures) is now supported for the RS/6000 family; the | |
651 compiler knows about more PPC chips. | |
652 | |
653 - Both NeXTStep 2.1 and 3 are supported on 68k-based architectures. | |
654 | |
655 - On the AMD 29k, the -msoft-float is now supported, as well as | |
656 -mno-sum-in-toc for RS/6000, -mapp-regs and -mflat for Sparc, and | |
657 -membedded-pic for MIPS. | |
658 | |
659 - GCC can now convert division by integer constants into the equivalent | |
660 multiplication and shift operations when that is faster than the | |
661 division. | |
662 | |
663 - Two new warning options, -Wbad-function-cast and | |
664 -Wmissing-declarations have been added. | |
665 | |
666 - Configurations may now add machine-specific __attribute__ options on | |
667 type; many machines support the `section' attribute. | |
668 | |
669 - The -ffast-math flag permits some optimization that violate strict | |
670 IEEE rules, such as converting X * 0.0 to 0.0. | |
671 | |
672 Noteworthy changes in GCC version 2.5.8: | |
673 | |
674 This release only fixes a few serious bugs. These include fixes for a | |
675 bug that prevented most programs from working on the RS/6000, a bug | |
676 that caused invalid assembler code for programs with a `switch' | |
677 statement on the NS32K, a G++ problem that caused undefined names in | |
678 some configurations, and several less serious problems, some of which | |
679 can affect most configuration. | |
680 | |
681 Noteworthy change in GCC version 2.5.7: | |
682 | |
683 This release only fixes a few bugs, one of which was causing bootstrap | |
684 compare errors on some systems. | |
685 | |
686 Noteworthy change in GCC version 2.5.6: | |
687 | |
688 A few backend bugs have been fixed, some of which only occur on one | |
689 machine. | |
690 | |
691 The C++ compiler in 2.5.6 includes: | |
692 | |
693 * fixes for some common crashes | |
694 * correct handling of nested types that are referenced as `foo::bar' | |
695 * spurious warnings about friends being declared static and never | |
696 defined should no longer appear | |
697 * enums that are local to a method in a class, or a class that's | |
698 local to a function, are now handled correctly. For example: | |
699 class foo { void bar () { enum { x, y } E; x; } }; | |
700 void bar () { class foo { enum { x, y } E; E baz; }; } | |
701 | |
702 Noteworthy change in GCC version 2.5.5: | |
703 | |
704 A large number of C++ bugs have been fixed. | |
705 | |
706 The fixproto script adds prototypes conditionally on __cplusplus. | |
707 | |
708 Noteworthy change in GCC version 2.5.4: | |
709 | |
710 A bug fix in passing of structure arguments for the HP-PA architecture | |
711 makes code compiled with GCC 2.5.4 incompatible with code compiled | |
712 with earlier versions (if it passes struct arguments of 33 to 64 bits, | |
713 interspersed with other types of arguments). | |
714 | |
715 Noteworthy change in gcc version 2.5.3: | |
716 | |
717 The method of "mangling" C++ function names has been changed. So you | |
718 must recompile all C++ programs completely when you start using GCC | |
719 2.5. Also, GCC 2.5 requires libg++ version 2.5. Earlier libg++ | |
720 versions won't work with GCC 2.5. (This is generally true--GCC | |
721 version M.N requires libg++ version M.N.) | |
722 | |
723 Noteworthy GCC changes in version 2.5: | |
724 | |
725 * There is now support for the IBM 370 architecture as a target. | |
726 Currently the only operating system supported is MVS; GCC does not run | |
727 on MVS, so you must produce .s files using GCC as a cross compiler, | |
728 then transfer them to MVS to assemble them. This port is not reliable | |
729 yet. | |
730 | |
731 * The Power PC is now supported. | |
732 | |
733 * The i860-based Paragon machine is now supported. | |
734 | |
735 * The Hitachi 3050 (an HP-PA machine) is now supported. | |
736 | |
737 * The variable __GNUC_MINOR__ holds the minor version number of GCC, as | |
738 an integer. For version 2.5.X, the value is 5. | |
739 | |
740 * In C, initializers for static and global variables are now processed | |
741 an element at a time, so that they don't need a lot of storage. | |
742 | |
743 * The C syntax for specifying which structure field comes next in an | |
744 initializer is now `.FIELDNAME='. The corresponding syntax for | |
745 array initializers is now `[INDEX]='. For example, | |
746 | |
747 char whitespace[256] | |
748 = { [' '] = 1, ['\t'] = 1, ['\n'] = 1 }; | |
749 | |
750 This was changed to accord with the syntax proposed by the Numerical | |
751 C Extensions Group (NCEG). | |
752 | |
753 * Complex numbers are now supported in C. Use the keyword __complex__ | |
754 to declare complex data types. See the manual for details. | |
755 | |
756 * GCC now supports `long double' meaningfully on the Sparc (128-bit | |
757 floating point) and on the 386 (96-bit floating point). The Sparc | |
758 support is enabled on Solaris 2.x because earlier system versions | |
759 (SunOS 4) have bugs in the emulation. | |
760 | |
761 * All targets now have assertions for cpu, machine and system. So you | |
762 can now use assertions to distinguish among all supported targets. | |
763 | |
764 * Nested functions in C may now be inline. Just declare them inline | |
765 in the usual way. | |
766 | |
767 * Packed structure members are now supported fully; it should be possible | |
768 to access them on any supported target, no matter how little alignment | |
769 they have. | |
770 | |
771 * To declare that a function does not return, you must now write | |
772 something like this (works only in 2.5): | |
773 | |
774 void fatal () __attribute__ ((noreturn)); | |
775 | |
776 or like this (works in older versions too): | |
777 | |
778 typedef void voidfn (); | |
779 | |
780 volatile voidfn fatal; | |
781 | |
782 It used to be possible to do so by writing this: | |
783 | |
784 volatile void fatal (); | |
785 | |
786 but it turns out that ANSI C requires that to mean something | |
787 else (which is useless). | |
788 | |
789 Likewise, to declare that a function is side-effect-free | |
790 so that calls may be deleted or combined, write | |
791 something like this (works only in 2.5): | |
792 | |
793 int computation () __attribute__ ((const)); | |
794 | |
795 or like this (works in older versions too): | |
796 | |
797 typedef int intfn (); | |
798 | |
799 const intfn computation; | |
800 | |
801 * The new option -iwithprefixbefore specifies a directory to add to | |
802 the search path for include files in the same position where -I would | |
803 put it, but uses the specified prefix just like -iwithprefix. | |
804 | |
805 * Basic block profiling has been enhanced to record the function the | |
806 basic block comes from, and if the module was compiled for debugging, | |
807 the line number and filename. A default version of the basic block | |
808 support module has been added to libgcc2 that appends the basic block | |
809 information to a text file 'bb.out'. Machine descriptions can now | |
810 override the basic block support module in the target macro file. | |
811 | |
812 New features in g++: | |
813 | |
814 * The new flag `-fansi-overloading' for C++. Use a newly implemented | |
815 scheme of argument matching for C++. It makes g++ more accurately | |
816 obey the rules set down in Chapter 13 of the Annotated C++ Reference | |
817 Manual (the ARM). This option will be turned on by default in a | |
818 future release. | |
819 | |
820 * The -finline-debug flag is now gone (it was never really used by the | |
821 compiler). | |
822 | |
823 * Recognizing the syntax for pointers to members, e.g., "foo::*bar", has been | |
824 dramatically improved. You should not get any syntax errors or incorrect | |
825 runtime results while using pointers to members correctly; if you do, it's | |
826 a definite bug. | |
827 | |
828 * Forward declaration of an enum is now flagged as an error. | |
829 | |
830 * Class-local typedefs are now working properly. | |
831 | |
832 * Nested class support has been significantly improved. The compiler | |
833 will now (in theory) support up to 240 nested classes before hitting | |
834 other system limits (like memory size). | |
835 | |
836 * There is a new C version of the `g++' driver, to replace the old | |
837 shell script. This should significantly improve the performance of | |
838 executing g++ on a system where a user's PATH environment variable | |
839 references many NFS-mounted filesystems. This driver also works | |
840 under MS-DOS and OS/2. | |
841 | |
842 * The ANSI committee working on the C++ standard has adopted a new | |
843 keyword `mutable'. This will allow you to make a specific member be | |
844 modifiable in an otherwise const class. | |
845 | |
846 Noteworthy GCC changes in version 2.4.4: | |
847 | |
848 A crash building g++ on various hosts (including m68k) has been | |
849 fixed. Also the g++ compiler no longer reports incorrect | |
850 ambiguities in some situations where they do not exist, and | |
851 const template member functions are now being found properly. | |
852 | |
853 Noteworthy GCC changes in version 2.4: | |
854 | |
855 * On each target, the default is now to return short structures | |
856 compatibly with the "usual" compiler on that target. | |
857 | |
858 For most targets, this means the default is to return all structures | |
859 in memory, like long structures, in whatever way is used on that | |
860 target. Use -freg-struct-return to enable returning short structures | |
861 (and unions) in registers. | |
862 | |
863 This change means that newly compiled binaries are incompatible with | |
864 binaries compiled with previous versions of GCC. | |
865 | |
866 On some targets, GCC is itself the usual compiler. On these targets, | |
867 the default way to return short structures is still in registers. | |
868 Use -fpcc-struct-return to tell GCC to return them in memory. | |
869 | |
870 * There is now a floating point emulator which can imitate the way all | |
871 supported target machines do floating point arithmetic. | |
872 | |
873 This makes it possible to have cross compilation to and from the VAX, | |
874 and between machines of different endianness. However, this works | |
875 only when the target machine description is updated to use the new | |
876 facilities, and not all have been updated. | |
877 | |
878 This also makes possible support for longer floating point types. | |
879 GCC 2.4 supports extended format on the 68K if you use `long double', | |
880 for targets that have a 68881. (When we have run time library | |
881 routines for extended floating point, then `long double' will use | |
882 extended format on all 68K targets.) | |
883 | |
884 We expect to support extended floating point on the i386 and Sparc in | |
885 future versions. | |
886 | |
887 * Building GCC now automatically fixes the system's header files. | |
888 This should require no attention. | |
889 | |
890 * GCC now installs an unsigned data type as size_t when it fixes the | |
891 header files (on all but a handful of old target machines). | |
892 Therefore, the bug that size_t failed to be unsigned is fixed. | |
893 | |
894 * Building and installation are now completely separate. | |
895 All new files are constructed during the build process; | |
896 installation just copies them. | |
897 | |
898 * New targets supported: Clipper, Hitachi SH, Hitachi 8300, and Sparc | |
899 Lite. | |
900 | |
901 * A totally new and much better Objective C run time system is included. | |
902 | |
903 * Objective C supports many new features. Alas, I can't describe them | |
904 since I don't use that language; however, they are the same ones | |
905 supported in recent versions of the NeXT operating system. | |
906 | |
907 * The builtin functions __builtin_apply_args, __builtin_apply and | |
908 __builtin_return let you record the arguments and returned | |
909 value of a function without knowing their number or type. | |
910 | |
911 * The builtin string variables __FUNCTION__ and __PRETTY_FUNCTION__ | |
912 give the name of the function in the source, and a pretty-printed | |
913 version of the name. The two are the same in C, but differ in C++. | |
914 | |
915 * Casts to union types do not yield lvalues. | |
916 | |
917 * ## before an empty rest argument discards the preceding sequence | |
918 of non-whitespace characters from the macro definition. | |
919 (This feature is subject to change.) | |
920 | |
921 | |
922 New features specific to C++: | |
923 | |
924 * The manual contains a new section ``Common Misunderstandings with | |
925 GNU C++'' that C++ users should read. | |
926 | |
927 * #pragma interface and #pragma implementation let you use the same | |
928 C++ source file for both interface and implementation. | |
929 However, this mechanism is still in transition. | |
930 | |
931 * Named returned values let you avoid an extra constructor call | |
932 when a function result has a class type. | |
933 | |
934 * The C++ operators <? and >? yield min and max, respectively. | |
935 | |
936 * C++ gotos can exit a block safely even if the block has | |
937 aggregates that require destructors. | |
938 | |
939 * gcc defines the macro __GNUG__ when compiling C++ programs. | |
940 | |
941 * GNU C++ now correctly distinguishes between the prefix and postfix | |
942 forms of overloaded operator ++ and --. To avoid breaking old | |
943 code, if a class defines only the prefix form, the compiler | |
944 accepts either ++obj or obj++, unless -pedantic is used. | |
945 | |
946 * If you are using version 2.3 of libg++, you need to rebuild it with | |
947 `make CC=gcc' to avoid mismatches in the definition of `size_t'. | |
948 | |
949 Newly documented compiler options: | |
950 | |
951 -fnostartfiles | |
952 Omit the standard system startup files when linking. | |
953 | |
954 -fvolatile-global | |
955 Consider memory references to extern and global data items to | |
956 be volatile. | |
957 | |
958 -idirafter DIR | |
959 Add DIR to the second include path. | |
960 | |
961 -iprefix PREFIX | |
962 Specify PREFIX for later -iwithprefix options. | |
963 | |
964 -iwithprefix DIR | |
965 Add PREFIX/DIR to the second include path. | |
966 | |
967 -mv8 | |
968 Emit Sparc v8 code (with integer multiply and divide). | |
969 -msparclite | |
970 Emit Sparclite code (roughly v7.5). | |
971 | |
972 -print-libgcc-file-name | |
973 Search for the libgcc.a file, print its absolute file name, and exit. | |
974 | |
975 -Woverloaded-virtual | |
976 Warn when a derived class function declaration may be an error | |
977 in defining a C++ virtual function. | |
978 | |
979 -Wtemplate-debugging | |
980 When using templates in a C++ program, warn if debugging is | |
981 not yet fully available. | |
982 | |
983 +eN | |
984 Control how C++ virtual function definitions are used | |
985 (like cfront 1.x). | |
986 | |
55
77e2b8dfacca
update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents:
0
diff
changeset
|
987 |
111 | 988 Copyright (C) 2000-2003 Free Software Foundation, Inc. |
55
77e2b8dfacca
update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents:
0
diff
changeset
|
989 |
77e2b8dfacca
update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents:
0
diff
changeset
|
990 Copying and distribution of this file, with or without modification, |
77e2b8dfacca
update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents:
0
diff
changeset
|
991 are permitted in any medium without royalty provided the copyright |
77e2b8dfacca
update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents:
0
diff
changeset
|
992 notice and this notice are preserved. |