package core_profiler

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Core_profiler_offline_tool.PathSource

The first and last points are stored explicitly, not least to ensure that there are two of them. The list of points in the middle is stored in reverse order for convenience when checking the path.

In a path, we might demand that we go from A -> B directly, or A -> B possibly via some other points. This is represented as { first = Direct_point a; last = b; ... } and { first = Point a; last = b; ... } respectively; that is, whether or not it must go directly is stored on the source, not the destination.

A final example: { first = Point a; middle_rev = [Direct_point b]; last = c } matches any sequence of points that starts at a, goes (possibly via some other distinct points) to b, and then directly from b to c.

This and the Event_generator.t do not have the full power of regular expressions Notably, the same point may not appear in a path twice, except for when its second appearance is the last point in the path.

Sourcetype 'a point =
  1. | Direct_point of 'a
  2. | Point of 'a
Sourceval sexp_of_point : ('a -> Ppx_sexp_conv_lib.Sexp.t) -> 'a point -> Ppx_sexp_conv_lib.Sexp.t
Sourceval point_of_sexp : (Ppx_sexp_conv_lib.Sexp.t -> 'a) -> Ppx_sexp_conv_lib.Sexp.t -> 'a point
Sourceval compare_point : ('a -> 'a -> int) -> 'a point -> 'a point -> int
Sourcetype 'a t = {
  1. first : 'a point;
  2. rest_rev : 'a point list;
  3. last : 'a;
}
include Ppx_sexp_conv_lib.Sexpable.S1 with type 'a t := 'a t
Sourceval t_of_sexp : (Sexplib0__.Sexp.t -> 'a) -> Sexplib0__.Sexp.t -> 'a t
Sourceval sexp_of_t : ('a -> Sexplib0__.Sexp.t) -> 'a t -> Sexplib0__.Sexp.t
Sourceval compare : ('a -> 'a -> int) -> 'a t -> 'a t -> int
Sourcemodule I : sig ... end
Sourceval string_t_of_string : string -> string t option
Sourceval string_t_to_string : string t -> string
Sourceval examples : string t list
Sourceval readme : string Core.Lazy.t
Sourceval lookup_names : Core_profiler.Probe_id.t t -> Reader.Header.t -> string t
Sourceval id_t_to_string : Core_profiler.Probe_id.t t -> ?with_group:string -> Reader.Header.t -> string
Sourceval first : 'a t -> 'a

Get t.first, discarding whether the first point is Direct_point or a Point

Sourceval last : 'a t -> 'a