[−][src]Struct llvm_ir_analysis::CrossModuleAnalysis
Analyzes multiple Module
s, providing a ModuleAnalysis
for each; and also
provides a few additional cross-module analyses (e.g., a cross-module call
graph)
Implementations
impl<'m> CrossModuleAnalysis<'m>
[src]
pub fn new(modules: impl IntoIterator<Item = &'m Module>) -> Self
[src]
Create a new CrossModuleAnalysis
for the given set of Module
s.
This method itself is cheap; individual analyses will be computed lazily on demand.
pub fn modules<'s>(&'s self) -> impl Iterator<Item = &'m Module> + 's
[src]
Iterate over the analyzed Module
(s).
pub fn functions<'s>(&'s self) -> impl Iterator<Item = &'m Function> + 's
[src]
Iterate over all the Function
s in the analyzed Module
(s).
pub fn call_graph(&self) -> Ref<'_, CallGraph<'m>>
[src]
Get the full CallGraph
for the Module
(s).
This will include both cross-module and within-module calls.
pub fn functions_by_type(&self) -> Ref<'_, FunctionsByType<'m>>
[src]
Get the FunctionsByType
for the Module
(s).
pub fn module_analysis<'s>(&'s self, mod_name: &str) -> &'s ModuleAnalysis<'m>
[src]
Get the ModuleAnalysis
for the module with the given name.
Panics if no module of that name exists in the Module
(s) which the
CrossModuleAnalysis
was created with.
pub fn get_func_by_name(
&self,
func_name: &str
) -> Option<(&'m Function, &'m Module)>
[src]
&self,
func_name: &str
) -> Option<(&'m Function, &'m Module)>
Get the Function
with the given name from the analyzed Module
(s).
Returns both the Function
and the Module
it was found in, or None
if no function was found with that name.
Auto Trait Implementations
impl<'m> !RefUnwindSafe for CrossModuleAnalysis<'m>
impl<'m> Send for CrossModuleAnalysis<'m>
impl<'m> !Sync for CrossModuleAnalysis<'m>
impl<'m> Unpin for CrossModuleAnalysis<'m>
impl<'m> UnwindSafe for CrossModuleAnalysis<'m>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,