blob: fb462b4a8bb7ceb31c91de01cb870b820020de54 [file] [log] [blame]
Reid Spencer4429b2c2004-09-11 04:54:06 +00001//===- Unix/SUS/Process.cpp - Linux Process Implementation ---- -*- C++ -*-===//
Misha Brukmanf976c852005-04-21 22:55:34 +00002//
Reid Spencer4429b2c2004-09-11 04:54:06 +00003// The LLVM Compiler Infrastructure
4//
Misha Brukmanf976c852005-04-21 22:55:34 +00005// This file was developed by Reid Spencer and is distributed under the
Reid Spencer4429b2c2004-09-11 04:54:06 +00006// University of Illinois Open Source License. See LICENSE.TXT for details.
Misha Brukmanf976c852005-04-21 22:55:34 +00007//
Reid Spencer4429b2c2004-09-11 04:54:06 +00008//===----------------------------------------------------------------------===//
9//
10// This file provides the Linux specific implementation of the Process class.
11//
12//===----------------------------------------------------------------------===//
13
14#include <unistd.h>
15
16//===----------------------------------------------------------------------===//
Misha Brukmanf976c852005-04-21 22:55:34 +000017//=== WARNING: Implementation here must contain only code specific to the
Reid Spencer4429b2c2004-09-11 04:54:06 +000018//=== SUS (Single Unix Specification).
19//===----------------------------------------------------------------------===//
20
21namespace llvm {
22using namespace sys;
23
Misha Brukmanf976c852005-04-21 22:55:34 +000024unsigned
Reid Spencer4429b2c2004-09-11 04:54:06 +000025Process::GetPageSize() {
26 static const long page_size = sysconf(_SC_PAGE_SIZE);
27 return static_cast<unsigned>(page_size);
28}
29
30}