File: bench_memory.Rd

package info (click to toggle)
r-cran-bench 1.1.4-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 712 kB
  • sloc: ansic: 339; sh: 13; makefile: 2
file content (26 lines) | stat: -rw-r--r-- 592 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/bench_time.R
\name{bench_memory}
\alias{bench_memory}
\title{Measure memory that an expression used.}
\usage{
bench_memory(expr)
}
\arguments{
\item{expr}{A expression to be measured.}
}
\value{
A tibble with two columns
\itemize{
\item The total amount of memory allocated
\item The raw memory allocations as parsed by \code{\link[profmem:readRprofmem]{profmem::readRprofmem()}}
}
}
\description{
Measure memory that an expression used.
}
\examples{
if (capabilities("profmem")) {
  bench_memory(1 + 1:10000)
}
}