📄 onews
字号:
calling sequence specified in the System V Application Binary Interface
Processor Supplement (PowerPC Processor ABI Supplement) rather than the calling
sequence used in GCC version 2.7.0. That calling sequence was based on the AIX
calling sequence without function descriptors. To compile code for that older
calling sequence, either configure the compiler for powerpc-*-eabiaix or use
the -mcall-aix switch when compiling and linking.
Noteworthy changes in GCC version 2.7.0
---------------------------------------
GCC now works better on systems that use ".obj" and ".exe" instead of
".o" and no extension. This involved changes to the driver program,
gcc.c, to convert ".o" names to ".obj" and to GCC's Makefile to use
".obj" and ".exe" in filenames that are not targets. In order to
build GCC on such systems, you may need versions of GNU make and/or
compatible shells. At this point, this support is preliminary.
Object file extensions of ".obj" and executable file extensions of
".exe" are allowed when using appropriate version of GNU Make.
Numerous enhancements were made to the __attribute__ facility including
more attributes and more places that support it. We now support the
"packed", "nocommon", "noreturn", "volatile", "const", "unused",
"transparent_union", "constructor", "destructor", "mode", "section",
"align", "format", "weak", and "alias" attributes. Each of these
names may also be specified with added underscores, e.g., "__packed__".
__attribute__ may now be applied to parameter definitions, function
definitions, and structure, enum, and union definitions.
GCC now supports returning more structures in registers, as specified by
many calling sequences (ABIs), such as on the HP PA RISC.
A new option '-fpack-struct' was added to automatically pack all structure
members together without holes.
There is a new library (cpplib) and program (cppmain) that at some
point will replace cpp (aka cccp). To use cppmain as cpp now, pass
the option CCCP=cppmain to make. The library is already used by the
fix-header program, which should speed up the fixproto script.
New options for supported targets:
GNU on many targets.
NetBSD on MIPS, m68k, VAX, and x86.
LynxOS on x86, m68k, Sparc, and RS/6000.
VxWorks on many targets.
Windows/NT on x86 architecture. Initial support for Windows/NT on Alpha
(not fully working).
Many embedded targets, specifically UDI on a29k, aout, coff, elf,
and vsta "operating systems" on m68k, m88k, mips, sparc, and x86.
Additional support for x86 (i386, i486, and Pentium):
Work with old and new linkers for Linux-based GNU systems,
supporting both a.out and ELF.
FreeBSD on x86.
Stdcall convention.
-malign-double, -mregparm=, -malign-loops= and -malign-jumps= switches.
On ISC systems, support -Xp like -posix.
Additions for RS/6000:
Instruction scheduling information for PowerPC 403.
AIX 4.1 on PowerPC.
-mstring and -mno-string.
-msoft-float and floating-point emulation included.
Preliminary support for PowerPC System V.4 with or without the GNU as.
Preliminary support for EABI.
Preliminary support for 64-bit systems.
Both big and little endian systems.
New features for MIPS-based systems:
r4650.
mips4 and R8000.
Irix 6.0.
64-bit ABI.
Allow dollar signs in labels on SGI/Irix 5.x.
New support for HP PA RISC:
Generation of PIC (requires binutils-2.5.2.u6 or later).
HP-UX version 9 on HP PA RISC (dynamically links even with -g).
Processor variants for HP PA RISC: 700, 7100, and 7100LC.
Automatic generation of long calls when needed.
-mfast-indirect-calls for kernels and static binaries.
The called routine now copies arguments passed by invisible reference,
as required by the calling standard.
Other new miscellaneous target-specific support:
-mno-multm on a29k.
-mold-align for i960.
Configuration for "semi-hosted" ARM.
-momit-leaf-frame-pointer for M88k.
SH3 variant of Hitachi Super-H and support both big and little endian.
Changes to Objective-C:
Bare-bones implementation of NXConstantString has been added,
which is invoked by the @"string" directive.
Class * has been changed to Class to conform to the NextSTEP and
OpenStep runtime.
Enhancements to make dynamic loading easier.
The module version number has been updated to Version 7, thus existing
code will need to be recompiled to use the current run-time library.
GCC now supports the ISO Normative Addendum 1 to the C Standard.
As a result:
The header <iso646.h> defines macros for C programs written
in national variants of ISO 646.
The following digraph tokens are supported:
<: :> <% %> %: %:%:
These behave like the following, respectively:
[ ] { } # ##
Digraph tokens are supported unless you specify the `-traditional'
option; you do not need to specify `-ansi' or `-trigraphs'. Except
for contrived and unlikely examples involving preprocessor
stringizing, digraph interpretation doesn't change the meaning of
programs; this is unlike trigraph interpretation, which changes the
meanings of relatively common strings.
The macro __STDC_VERSION__ has the value 199409L.
As usual, for full conformance to the standard, you also need a
C library that conforms.
The following lists changes that have been made to g++. If some
features mentioned below sound unfamiliar, you will probably want to
look at the recently-released public review copy of the C++ Working
Paper. For PostScript and PDF (Adobe Acrobat) versions, see the
archive at ftp://research.att.com/dist/stdc++/WP. For HTML and ASCII
versions, see ftp://ftp.cygnus.com/pub/g++. On the web, see
http://www.cygnus.com/~mrs/wp-draft.
The scope of variables declared in the for-init-statement has been changed
to conform to http://www.cygnus.com/~mrs/wp-draft/stmt.html#stmt.for; as a
result, packages such as groff 1.09 will not compile unless you specify the
-fno-for-scope flag. PLEASE DO NOT REPORT THIS AS A BUG; this is a change
mandated by the C++ standardization committee.
Binary incompatibilities:
The builtin 'bool' type is now the size of a machine word on RISC targets,
for code efficiency; it remains one byte long on CISC targets.
Code that does not use #pragma interface/implementation will most
likely shrink dramatically, as g++ now only emits the vtable for a
class in the translation unit where its first non-inline, non-abstract
virtual function is defined.
Classes that do not define the copy constructor will sometimes be
passed and returned in registers. This may illuminate latent bugs in
your code.
Support for automatic template instantiation has *NOT* been added, due
to a disagreement over design philosophies.
Support for exception handling has been improved; more targets are now
supported, and throws will use the RTTI mechanism to match against the
catch parameter type. Optimization is NOT SUPPORTED with
-fhandle-exceptions; no need to report this as a bug.
Support for Run-Time Type Identification has been added with -frtti.
This support is still in alpha; one major restriction is that any file
compiled with -frtti must include <typeinfo.h>.
Preliminary support for namespaces has been added. This support is far
from complete, and probably not useful.
Synthesis of compiler-generated constructors, destructors and
assignment operators is now deferred until the functions are used.
The parsing of expressions such as `a ? b : c = 1' has changed from
`(a ? b : c) = 1' to `a : b ? (c = 1)'.
The code generated for testing conditions, especially those using ||
and &&, is now more efficient.
The operator keywords and, and_eq, bitand, bitor, compl, not, not_eq,
or, or_eq, xor and xor_eq are now supported. Use -ansi or
-foperator-names to enable them.
The 'explicit' keyword is now supported. 'explicit' is used to mark
constructors and type conversion operators that should not be used
implicitly.
g++ now accepts the typename keyword, though it currently has no
semantics; it can be a no-op in the current template implementation.
You may want to start using it in your code, however, since the
pending rewrite of the template implementation to compile STL properly
(perhaps for 2.8.0, perhaps not) will require you to use it as
indicated by the current draft.
Handling of user-defined type conversion has been overhauled so that
type conversion operators are now found and used properly in
expressions and function calls.
-fno-strict-prototype now only applies to function declarations with
"C" linkage.
g++ now warns about 'if (x=0)' with -Wparentheses or -Wall.
#pragma weak and #pragma pack are supported on System V R4 targets, as
are various other target-specific #pragmas supported by gcc.
new and delete of const types is now allowed (with no additional
semantics).
Explicit instantiation of template methods is now supported. Also,
'inline template class foo<int>;' can be used to emit only the vtable
for a template class.
With -fcheck-new, g++ will check the return value of all calls to
operator new, and not attempt to modify a returned null pointer.
The template instantiation code now handles more conversions when
passing to a parameter that does not depend on template arguments.
This means that code like 'string s; cout << s;' now works.
Invalid jumps in a switch statement past declarations that require
initializations are now caught.
Functions declared 'extern inline' now have the same linkage semantics
as inline member functions. On supported targets, where previously
these functions (and vtables, and template instantiations) would have
been defined statically, they will now be defined as weak symbols so
that only one out-of-line definition is used.
collect2 now demangles linker output, and c++filt has become part of
the gcc distribution.
Noteworthy changes in GCC version 2.6.3:
A few more bugs have been fixed.
Noteworthy changes in GCC version 2.6.2:
A few bugs have been fixed.
Names of attributes can now be preceded and followed by double underscores.
Noteworthy changes in GCC version 2.6.1:
Numerous (mostly minor) bugs have been fixed.
The following new configurations are supported:
GNU on x86 (instead of treating it like MACH)
NetBSD on Sparc and Motorola 68k
AIX 4.1 on RS/6000 and PowerPC systems
Sequent DYNIX/ptx 1.x and 2.x.
Both COFF and ELF configurations on AViiON without using /bin/gcc
Windows/NT on x86 architecture; preliminary
AT&T DSP1610 digital signal processor chips
i960 systems on bare boards using COFF
PDP11; target only and not extensively tested
The -pg option is now supported for Alpha under OSF/1 V3.0 or later.
Files with an extension of ".c++" are treated as C++ code.
The -Xlinker and -Wl arguments are now passed to the linker in the
position they were specified on the command line. This makes it
possible, for example, to pass flags to the linker about specific
object files.
The use of positional arguments to the configure script is no longer
recommended. Use --target= to specify the target; see the GCC manual.
The 386 now supports two new switches: -mreg-alloc=<string> changes
the default register allocation order used by the compiler, and
-mno-wide-multiply disables the use of the mul/imul instructions that
produce 64 bit results in EAX:EDX from 32 bit operands to do long long
multiplies and 32-bit division by constants.
Noteworthy changes in GCC version 2.6.0:
Numerous bugs have been fixed, in the C and C++ front-ends, as
well as in the common compiler code.
This release includes the C, Objective-C, and C++ compilers. However,
we have moved the files for the C++ compiler (G++) files to a
subdirectory, cp. Subsequent releases of GCC will split these files
to a separate TAR file.
The G++ team has been tracking the development of the ANSI standard for C++.
Here are some new features added from the latest working paper:
* built-in boolean type 'bool', with constants 'true' and 'false'.
* array new and delete (operator new [] and delete []).
* WP-conforming lifetime of temporaries.
* explicit instantiation of templates (template class A<int>;),
along with an option (-fno-implicit-templates) to disable emission
of implicitly instantiated templates, obsoletes -fexternal-templates.
* static member constants (static const int foo = 4; within the
class declaration).
Many error messages have been improved to tell the user more about the
problem. Conformance checking with -pedantic-errors has been
improved. G++ now compiles Fresco.
There is now an experimental implementation of virtual functions using
thunks instead of Cfront-style vtables, enabled with -fvtable-thunks.
This option also enables a heuristic which causes the compiler to only
emit the vtable in the translation unit where its first non-inline
virtual function is defined; using this option and
-fno-implicit-templates, users should be able to avoid #pragma
interface/implementation altogether.
Signatures have been added as a GNU C++ extension. Using the option
-fhandle-signatures, users are able to turn on recognition of
signatures. A short introduction on signatures is in the section
`Extension to the C++ Language' in the manual.
The `g++' program is now a C program, rather than a shell script.
Lots and lots and lots of bugs fixes, in nested types, access control,
pointers to member functions, the parser, templates, overload
resolution, etc, etc.
There have been two major enhancements to the Objective-C compiler:
1) Added portability. It now runs on Alpha, and some problems with
message forwarding have been addressed on other platforms.
2) Selectors have been redefined to be pointers to structs like:
{ void *sel_id, char *sel_types }, where the sel_id is the unique
identifier, the selector itself is no longer unique.
Programmers should use the new function sel_eq to test selector
equivalence.
The following major changes have been made to the base compiler and
machine-specific files.
- The MIL-STD-1750A is a new port, but still preliminary.
- The h8/300h is now supported; both the h8/300 and h8/300h ports come
with 32 bit IEEE 754 software floating point support.
- The 64-bit Sparc (v9) and 64-bit MIPS chips are supported.
- NetBSD is supported on m68k, Intel x86, and pc523 systems and FreeBSD
on x86.
- COFF is supported on x86, m68k, and Sparc systems running LynxOS.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -