Sun Studio 12: C++ User's Guide

A.2.175.1 -xtargetValues By Platform

Table A–48 -xtarget Values for All Platforms

Value 

Meaning  

native

Gets the best performance on the host system. The compiler generates code optimized for the host system. It determines the available architecture, chip, and cache properties of the machine on which the compiler is running. 

native64

Gets the best performance for 64-bit object binaries on the host system. The compiler generates 64-bit object binaries optimized for the host system. It determines the available 64-bit architecture, chip, and cache properties of the machine on which the compiler is running. 

generic

This is the default value. Gets the best performance for generic architecture, chip, and cache. 

generic64

Sets the parameters for the best performance of 64-bit object binaries over most 64-bit platform architectures. 

system-name

Gets the best performance for the specified platform.  

Select a system name from the following lists for which represents the actual system you are targeting. 

-xtarget Values on SPARC Platforms

Compiling for 64-bit Solaris software on SPARC or UltraSPARC V9 is indicated by the -m64 option. If you specify -xtarget with a flag other than native64 or generic64, you must also specify the -m64 option as follows: -xtarget=ultra... -m64 otherwise the compiler uses a 32-bit memory model.

Table A–49 -xtargetExpansions on SPARC Architecture

-xtarget=  

-xarch  

-xchip  

-xcache  

generic

generic

generic

generic

cs6400

v8plusa

super

16/32/4:2048/64/1

entr150

v8plusa

ultra

16/32/1:512/64/1

entr2

v8plusa

ultra

16/32/1:512/64/1

entr2/1170

v8plusa

ultra

16/32/1:512/64/1

entr2/1200

v8plusa

ultra

16/32/1:512/64/1

entr2/2170

v8plusa

ultra

16/32/1:512/64/1

entr2/2200

v8plusa

ultra

16/32/1:512/64/1

entr3000

v8plusa

ultra

16/32/1:512/64/1

entr4000

v8plusa

ultra

16/32/1:512/64/1

entr5000

v8plusa

ultra

16/32/1:512/64/1

entr6000

v8plusa

ultra

16/32/1:512/64/1

sc2000

v8plusa

super

16/32/4:2048/64/1

solb5

v7

old

128/32/1

solb6

v8

super

16/32/4:1024/32/1

ss1

v7

old

64/16/1

ss10

v8

super

16/32/4

ss10/20

v8

super

16/32/4

ss10/30

v8

super

16/32/4

ss10/40

v8

super

16/32/4

ss10/402

v8

super

16/32/4

ss10/41

v8

super

16/32/4:1024/32/1

ss10/412

v8

super

16/32/4:1024/32/1

ss10/50

v8

super

16/32/4

ss10/51

v8

super

16/32/4:1024/32/1

ss10/512

v8

super

16/32/4:1024/32/1

ss10/514

v8

super

16/32/4:1024/32/1

ss10/61

v8

super

16/32/4:1024/32/1

ss10/612

v8

super

16/32/4:1024/32/1

ss10/71

v8

super2

16/32/4:1024/32/1

ss10/712

v8

super2

16/32/4:1024/32/1

ss10/hs11

v8

hyper

256/64/1

ss10/hs12

v8

hyper

256/64/1

ss10/hs14

v8

hyper

256/64/1

ss10/hs21

v8

hyper

256/64/1

ss10/hs22

v8

hyper

256/64/1

ss1000

v8

super

16/32/4:1024/32/1

ss1plus

v7

old

64/16/1

ss2

v7

old

64/32/1

ss20

v8

super

16/32/4:1024/32/1

ss20/151

v8

hyper

512/64/1

ss20/152

v8

hyper

512/64/1

ss20/50

v8

super

16/32/4

ss20/502

v8

super

16/32/4

ss20/51

v8

super

16/32/4:1024/32/1

ss20/512

v8

super

16/32/4:1024/32/1

ss20/514

v8

super

16/32/4:1024/32/1

ss20/61

v8

super

16/32/4:1024/32/1

ss20/612

v8

super

16/32/4:1024/32/1

ss20/71

v8

super2

16/32/4:1024/32/1

ss20/712

v8

super2

16/32/4:1024/32/1

ss20/hs11

v8

hyper

256/64/1

ss20/hs12

v8

hyper

256/64/1

ss20/hs14

v8

hyper

256/64/1

ss20/hs21

v8

hyper

256/64/1

ss20/hs22

v8

hyper

256/64/1

ss2p

v7

powerup

64/32/1

ss4

v8a

micro2

8/16/1

ss4/110

v8a

micro2

8/16/1

ss4/85

v8a

micro2

8/16/1

ss5

v8a

micro2

8/16/1

ss5/110

v8a

micro2

8/16/1

ss5/85

v8a

micro2

8/16/1

ss600/120

v7

old

64/32/1

ss600/140

v7

old

64/32/1

ss600/41

v8

super

16/32/4:1024/32/1

ss600/412

v8

super

16/32/4:1024/32/1

ss600/51

v8

super

16/32/4:1024/32/1

ss600/512

v8

super

16/32/4:1024/32/1

ss600/514

v8

super

16/32/4:1024/32/1

ss600/61

v8

super

16/32/4:1024/32/1

ss600/612

v8

super

16/32/4:1024/32/1

sselc

v7

old

64/32/1

ssipc

v7

old

64/16/1

ssipx

v7

old

64/32/1

sslc

v8a

micro

2/16/1

sslt

v7

old

64/32/1

sslx

v8a

micro

2/16/1

sslx2

v8a

micro2

8/16/1

ssslc

v7

old

64/16/1

ssvyger

v8a

micro2

8/16/1

sun4/110

v7

old

2/16/1

sun4/15

v8a

micro

2/16/1

sun4/150

v7

old

2/16/1

sun4/20

v7

old

64/16/1

sun4/25

v7

old

64/32/1

sun4/260

v7

old

128/16/1

sun4/280

v7

old

128/16/1

sun4/30

v8a

micro

2/16/1

sun4/330

v7

old

128/16/1

sun4/370

v7

old

128/16/1

sun4/390

v7

old

128/16/1

sun4/40

v7

old

64/16/1

sun4/470

v7

old

128/32/1

sun4/490

v7

old

128/32/1

sun4/50

v7

old

64/32/1

sun4/60

v7

old

64/16/1

sun4/630

v7

old

64/32/1

sun4/65

v7

old

64/16/1

sun4/670

v7

old

64/32/1

sun4/690

v7

old

64/32/1

sun4/75

v7

old

64/32/1

ultra

v8plusa

ultra

16/32/1:512/64/1

ultra1/140

v8plusa

ultra

16/32/1:512/64/1

ultra1/170

v8plusa

ultra

16/32/1:512/64/1

ultra1/200

v8plusa

ultra

16/32/1:512/64/1

ultra2

v8plusa

ultra2

16/32/1:512/64/1

ultra2/1170

v8plusa

ultra

16/32/1:512/64/1

ultra2/1200

v8plusa

ultra

16/32/1:1024/64/1

ultra2/1300

v8plusa

ultra2

16/32/1:2048/64/1

ultra2/2170

v8plusa

ultra

16/32/1:512/64/1

ultra2/2200

v8plusa

ultra

16/32/1:1024/64/1

ultra2/2300

v8plusa

ultra2

16/32/1:2048/64/1

ultra2e

v8plusa

ultra2e

16/32/1:256/64/4

ultra2i

v8plusa

ultra2i

16/32/1:512/64/1

ultra3

v8plusa

ultra3

64/32/4:8192/512/1

ultra3cu

v8plusa

ultra3cu

64/32/4:8192/512/2

ultra3i

v8plusa

ultra3i

64/32/4:1024/64/4

ultra4

v8plusa

ultra4

64/32/4:8192/128/2

ultra4plus

v8plusa

ultra4plus

64/32/4:2048/64/4:32768/64/4

ultraT1

v8plusa

ultraT1

8/16/4/4:3072/64/12/32

ultraT2

sparcvis2

ultraT2

8/16/4:4096/64/16

sparc64vi

sparcfmaf

sparc64vi

128/64/2:5120/64/10

See A.2.111 –xcache=c for more information on the cache properties of the UltraSPARC IVplus, UltraSPARC T1, and UltraSPARC T2 chips.

-xtarget Values on x86 Platforms

Compiling for 64-bit Solaris software on 64-bit x86 platforms is indicated by the -m64 option. If you specify -xtarget with a flag other than native64 or generic64, you must also specify the -m64 option as follows: -xtarget=opteron ... -m64 otherwise the compiler uses a 32-bit memory model.

Table A–50 -xtarget Values on x86 Platforms

-xtarget=  

-xarch  

-xchip  

-xcache  

generic

generic

generic

generic

opteron 

sse2 

opteron

64/64/2:1024/64/16

pentium

386

pentium

generic

pentium_pro

pentium_pro

pentium_pro

generic

pentium3 

sse 

pentium3

16/32/4:256/32/4 

pentium4 

sse2 

pentium4

8/64/4:256/128/8 

Defaults

On both SPARC and x86 devices, if –xtarget is not specified, –xtarget=generic is assumed.

Expansions

The –xtarget option is a macro that permits a quick and easy specification of the -xarch, –xchip, and –xcache combinations that occur on commercially purchased platforms. The only meaning of –xtarget is in its expansion.

Examples

-xtarget=sun4/15 means -xarch=v8a -xchip=micro -xcache=2/16/1.

Interactions

Compilation for SPARC V9 architecture indicated by the -xarch=v9|v9a|v9b option. Setting –xtarget=ultra or ultra2 is not necessary or sufficient. If -xtarget is specified, the -xarch=v9, v9a, or v9b option must appear after the -xtarget. For example:


-xarch=v9 -xtarget=ultra

expands to the following and reverts the -xarch value to v8.


-xarch=v9 -xarch=v8 -xchip=ultra -xcache=16/32/1:512/64/1

The correct method is to specify -xarch after -xtarget. For example:


–xtarget=ultra -xarch=v9

Warnings

When you compile and link in separate steps, you must use the same -xtarget settings in the compile step and the link step.