Red Hat ENTERPRISE LINUX 3 - DEVELOPER TOOLS GUIDE Dokumentacja Strona 22

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 110
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 21
Red Hat Enterprise Linux to Oracle Solaris Porting Guide
21
The story is little different for member data in a structure, union, or class objects. The struct
member variables must be aligned to the highest bytes of the size of any member variables to prevent
performance penalties.
// 4-byte alignment
struct mystruct
{
char a; // size = 1 byte
// 3 bytes padding
int i; // size = 4 bytes
};
In the above example, the size of mystruct is 8 bytes.
// 8-byte alignment
struct mystruct_1
{
char a; // size = 1 byte
// 7 bytes padding
double i; // size = 8 bytes
};
In the above example, the size of mystruct_1 is 16 bytes.
Low-Level Code, Bit-Level Operations
When migrating from a 32-bit RHEL application to a 64-bit Oracle Solaris SPARC application, the
bit-shifting operations used inattentively in typical legacy C code can cause lots of problems. The
following example is a function that does a shift operation. Note that untyped integral constants are of
type unsigned int. During shifting, this can lead to unexpected truncation.
For example, in the following code, the maximum value for
i can be 31. This is because the type of
1 << i” is int.
long j = 1 << i;
To get the shift done on a 64-bit SPARC system, 1L should be used, as shown below:
long j = 1L << i;
System APIs
System Call Mapping
Both RHEL and Oracle Solaris are UNIX operating systems that follow the POSIX standard. Both
provide well-defined system call interfaces. Most of the system calls available on RHEL are also
Przeglądanie stron 21
1 2 ... 17 18 19 20 21 22 23 24 25 26 27 ... 109 110

Komentarze do niniejszej Instrukcji

Brak uwag

Approx Tablettes manuels d'utilisation

La liste de Approx Tablettes produits contient 14 manuels d'utilisation pour les modèles 14. Tous les guides d'utilisation en format pdf peuvent être téléchargés ou consultés en ligne.

Cliquez sur un alphabet ci-dessous pour faire défiler la liste complète des modèles commençant par cette lettre

Modèles Type de document
appTB101S
Fiche technique   Approx Cheesecake Tab XM 16GB 3G Black, 2 pages
APPTB102S
Fiche technique   Approx Cheesecake Tab XL 2 16GB 3G Black, 2 pages
APPTB103S
Fiche technique   Approx Cheesecake XL QUAD 8GB Black, Silver, 2 pages
APPTB103V2
Fiche technique   Approx Cheesecake XL QUAD 8GB Black, Silver, 2 pages
APPTB104B
Fiche technique   Approx Cheesecake 10.1'' XL 8GB 3G Black, 2 pages
APPTB105B
Fiche technique   Approx Cheesecake XL 2 8GB Black, 2 pages
APPTB106B
Fiche technique   Approx Cheesecake XL QUAD 8GB Black, 2 pages
APPTB700B
Fiche technique   Approx Cheesecake LITE 8GB 3G Black, 2 pages
APPTB702
Fiche technique   Approx Cheesecake Lite + 4GB 3G Black, 2 pages
APPTB800S
Fiche technique   Approx Cheesecake Tab XM 8GB 3G Black, 2 pages
Cheesecake Tab 7.0
Guide d'installation        Approx Cheesecake Tab 7.0 8GB Black, 30 pages
KIDS
Guide d'installation    Approx Cheesecake KIDS 8GB Black, Red, 54 pages
Lite 3
Guide d'installation       Approx Cheesecake Lite 3 4GB Black, 72 pages
Tab 7.0 V2
Guide d'installation       Approx Cheesecake Tab 7.0 V2 8GB 3G Black, 48 pages