HP aC++/HP C A.06.25 Release Notes

Table Of Contents
Definition: foo.c:uint64_t variable[SIZE];
Reference: bar.c:extern uint64_t variable;
ld: The value 0xXXX does not fit when applying the relocation GPREL22 for
symbol "variable" at offset 0xYYY in section index ZZZ of file bar.o.
Workaround: The declaration should be changed to:
extern uint64_t variable[];
This error can also occur in assembly code if items <= 8 bytes are put into.data/.bss
instead of .sdata/.sbss.
Workaround (assembler): For "small" variables defined in assembly, change the section
name from .bss to .sbss or .data to .sdata:
.section .sdata = "asw", "progbits"
.align 8
gggggggg:: data4 0x000003e7
Object Files Generated at +O4 or -ipo
Object files generated by the compiler at optimization level 4, called intermediate object
files, are intended to be temporary files. These object files contain an intermediate
representation of the user code in a format that is designed for advanced optimizations.
The size of these intermediate object files may be 3 to 10 times as large as normal object
files. Hewlett-Packard reserves the right to change the format of these files without
notice in any compiler release or patch. Use of intermediate files must be limited to the
compiler that created them. For the same reason, intermediate object files should not
be included in archived libraries that might be used by different versions of the compiler.
When an incompatible intermediate file is detected, the compiler issues a message and
terminates.
Because we do not guarantee the iELF compatibility across major releases, we strongly
recommend that customers who mix Fortran with C/C++ use the same version of the
compiler when they use -ipo.
Refer to the discussion of tunables in the Installation section for additional information.
Incompatibilities Between the Standard C++ Library Ver. 1.2.1 and the Draft
Standard
As the ANSI C++ standard has evolved over time, the Standard C++ Library has not
always kept up. Such is the case for the times function object in the functional header
file. In the standard, times has been renamed to multiplies.
If you want to use multiplies in your code, to be compatible with the ISO/ANSI C++
standard, use a conditional compilation flag on the aCC command line.
For example, for the following program, compile with the command line:
aCC -D__HPACC_USING_MULTIPLIES_IN_FUNCTIONAL test.c
// test.c
int times; //user defined variable
48 Known Problems and Workarounds