crucible-llvm-0.6: Support for translating and executing LLVM code in Crucible
Copyright(c) Galois Inc 2011-2018
LicenseBSD3
MaintainerJoe Hendrix <jhendrix@galois.com>
Stabilityprovisional
Safe HaskellSafe-Inferred
LanguageHaskell2010

Lang.Crucible.LLVM.TypeContext

Description

This module provides functionality for querying simulator type information in a module, and converting llvm-pretty types into simulator types.

Synopsis

LLVMContext

data TypeContext Source #

Provides information about the types in an LLVM bitcode file.

Instances

Instances details
Show TypeContext Source # 
Instance details

Defined in Lang.Crucible.LLVM.TypeContext

mkTypeContext :: DataLayout -> MetadataMap -> [TypeDecl] -> ([Doc ann], TypeContext) Source #

Creates an LLVMContext from a parsed data layout and lists of types. Errors reported in first argument.

typeContextFromModule :: Module -> ([Doc ann], TypeContext) Source #

Utility function to creates an LLVMContext directly from a model.

LLVMContext query functions.

compatMemTypes :: MemType -> MemType -> Bool Source #

Returns true if types are bit-level compatible.

asMemType :: (?lc :: TypeContext, MonadError String m) => SymType -> m MemType Source #

If argument corresponds to a MemType possibly via aliases, then return it. Otherwise, returns Nothing.