[][src]Struct twiggy_ir::Items

pub struct Items { /* fields omitted */ }

The architecture- and target-independent internal representation of functions, sections, etc in a file that is being size profiled.

Constructed with ItemsBuilder.


impl Items[src]

Important traits for Iter<'a>
pub fn iter(&self) -> Iter[src]

Iterate over all of the IR items.

Important traits for Neighbors<'a>
pub fn neighbors(&self, id: Id) -> Neighbors[src]

Iterate over an item's neighbors.

Important traits for Predecessors<'a>
pub fn predecessors(&self, id: Id) -> Predecessors[src]

Iterate over an item's predecessors.

pub fn size(&self) -> u32[src]

The size of the total binary, containing all items.

pub fn meta_root(&self) -> Id[src]

Get the id of the "meta root" which is a single root item with edges to all of the real roots.

pub fn compute_predecessors(&mut self)[src]

Force computation of predecessors.

pub fn compute_dominators(&mut self)[src]

Compute dominators for each item.

pub fn immediate_dominators(&self) -> &BTreeMap<Id, Id>[src]

Get a refercence to immediate dominators

pub fn compute_dominator_tree(&mut self)[src]

Force computation of the dominator tree.

pub fn dominator_tree(&self) -> &BTreeMap<Id, Vec<Id>>[src]

Get a reference to the dominator tree.

Must have already called compute_dominator_tree.

pub fn compute_retained_sizes(&mut self)[src]

Force computation of the retained sizes of each IR item.

pub fn retained_size(&self, id: Id) -> u32[src]

Get the given item's retained size.

pub fn get_item_by_name(&self, name: &str) -> Option<&Item>[src]

Get an item with the given name.

Trait Implementations

impl Index<Id> for Items[src]

type Output = Item

The returned type after indexing.

impl Debug for Items[src]

impl<'a> IntoNeighbors for &'a Items[src]

type Neighbors = Neighbors<'a>

impl Visitable for Items[src]

type Map = HashSet<Id>

The associated map type

impl GraphBase for Items[src]

type EdgeId = ()

edge identifier

type NodeId = Id

node identifier

impl NodeCount for Items[src]

Auto Trait Implementations

impl Send for Items

impl Sync for Items

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 

type Error = !

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized

impl<T, U> TryInto for T where
    U: TryFrom<T>, 

type Error = <U as TryFrom<T>>::Error

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized

impl<T> BorrowMut for T where
    T: ?Sized