Ne.app NeANT
The Ne.app NeANT User module of the NeANT distribution.
Data Structures | Macros | Typedefs | Functions
alloc.cpp File Reference
#include <stdlib.h>
#include <string.h>
#include <rw_alloc.h>
#include <rw_driver.h>
#include <unistd.h>
#include <sys/mman.h>
#include <sys/types.h>
Include dependency graph for alloc.cpp:

Go to the source code of this file.

Data Structures

struct  BlockInfo
 
struct  Stats
 
struct  Blocks
 
struct  Pair
 
class  MemRWGuard
 

Macros

#define _RWSTD_TEST_SRC
 
#define GETPAGESIZE()   getpagesize ()
 
#define MAP_PRIVATE   0
 
#define MAP_ANONYMOUS   0
 

Typedefs

typedef _RWSTD_MUNMAP_ARG1_T CaddrT
 

Functions

_TEST_EXPORT void * rw_alloc (size_t nbytes, int flags)
 
_TEST_EXPORT void rw_free (void *addr)
 

Macro Definition Documentation

◆ _RWSTD_TEST_SRC

#define _RWSTD_TEST_SRC

alloc.cpp - definitions of rw_alloc and rw_free

$Id$

Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Definition at line 28 of file alloc.cpp.

◆ GETPAGESIZE

#define GETPAGESIZE ( )    getpagesize ()

Definition at line 55 of file alloc.cpp.

◆ MAP_ANONYMOUS

#define MAP_ANONYMOUS   0

Definition at line 171 of file alloc.cpp.

◆ MAP_PRIVATE

#define MAP_PRIVATE   0

Definition at line 166 of file alloc.cpp.

Typedef Documentation

◆ CaddrT

typedef _RWSTD_MUNMAP_ARG1_T CaddrT

Definition at line 65 of file alloc.cpp.

Function Documentation

◆ rw_alloc()

_TEST_EXPORT void * rw_alloc ( size_t  nbytes,
int  flags 
)

Definition at line 537 of file alloc.cpp.

◆ rw_free()

_TEST_EXPORT void rw_free ( void *  addr)

Definition at line 621 of file alloc.cpp.