8.13. Expensive System Calls

The most expensive system calls from the standpoint of memory are fork(2) and exec(2), malloc(2), and mmap(2). Fork(2) and exec(2) require extensive new memory allocation for VAS/pregion structures; vfork(2) offers a partial remedy (see Section 8.5.1, “fork and vfork” on page 235).

Malloc(2) and mmap(2) also are expensive calls because they have a high amount of overhead per invocation, so calling them frequently can result in high CPU overhead.

Get HP-UX 11i Tuning and Performance now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.