report

package
v0.0.0-...-64c0246 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 16, 2017 License: BSD-3-Clause Imports: 14 Imported by: 0

Documentation

Overview

Package report summarizes a performance profile into a human-readable report.

Index

Constants

View Source
const (
	Proto = iota
	Dot
	Tags
	Tree
	Text
	Raw
	Dis
	List
	WebList
	Callgrind
)

Output formats.

Variables

This section is empty.

Functions

func Generate

func Generate(w io.Writer, rpt *Report, obj plugin.ObjTool) error

Generate generates a report as directed by the Report.

func ScaleValue

func ScaleValue(value int64, fromUnit, toUnit string) (sv float64, su string)

ScaleValue reformats a value from a unit to a different unit.

Types

type Options

type Options struct {
	OutputFormat int

	CumSort        bool
	CallTree       bool
	PrintAddresses bool
	DropNegative   bool
	Ratio          float64

	NodeCount    int
	NodeFraction float64
	EdgeFraction float64

	SampleType string
	SampleUnit string // Unit for the sample data from the profile.
	OutputUnit string // Units for data formatting in report.

	Symbol *regexp.Regexp // Symbols to include on disassembly report.
}

Options are the formatting and filtering options used to generate a profile.

type Report

type Report struct {
	// contains filtered or unexported fields
}

Report contains the data and associated routines to extract a report from a profile.

func New

func New(prof *profile.Profile, options Options, value func(s *profile.Sample) int64, unit string) *Report

New builds a new report indexing the sample values interpreting the samples with the provided function.

func NewDefault

func NewDefault(prof *profile.Profile, options Options) *Report

NewDefault builds a new report indexing the sample values with the last value available.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL