HP aC++/HP C Programmer's Guide (B3901-90036; A.06.26; September 2011)
Table 3 Size and Alignment of HP Compiler Data Types (continued)
AlignmentSize (in bytes)Data Type
*** struct and union alignment are same and follow strict alignment of any member. Padding is done
to a multiple of the alignment size.
-fshort-enums
cc -Agcc -Wc,--fshort-enums foo.c
aCC -Ag++ -Wc,--fshort-enums foo.c
The -fshort-enums option is used with the -Agcc or -Ag++ options to cause each
enum type to be represented using the smallest integer type that is capable of representing
all values of the enum type. Because it changes the representation of types, the code
generated is not binary compatible with code compiled without the option. The primary
use of this option is for compatibility with gcc, but it can provide performance
improvement to applications that can accept the binary incompatibility.
+unum
+unum
The +unum option allows pointers to access non-natively aligned data. This option alters
the way that the compiler accesses dereferenced data. Use of this option may reduce
the efficiency of generated code. Specify num as 1, 2, or 4, as follows:
1 - Assume single byte alignment. Dereferences are performed with a series of single-byte
loads and stores.
2 - Dereferences are performed with a series of two-byte loads and stores.
4 - Dereferences are performed with a series of four-byte loads and stores.
Example:
aCC +u1 app.C
Debugging Options
Debugging options enable you to use the HP WDB debugger.
Information on HP WDB is available at this location: http://www.hp.com/go/wdb
+d
The +d option prevents the expansion of inline functions. It is useful when you debug
code because breakpoints cannot be set at inline functions. Using the +d option disables
all inlining. It is mapped to the +inline_level 0 option.
Debugging Options 39