# Interface: com.pnfsoftware.jeb.core.units.code.asm.decompiler.IEGlobalContext

Global IR context. A native decompiler instance holds a single global IR context. The global context is also a factory for non\-local IR objects, such as IR constants or IR operations.

## Method: addRoutineContext
- parameter: `ctx`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.IERoutineContext`

Description: Register a routine context with this global context.
parameter: ctx: 

## Method: buildEmptyState
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.EState`

Description: Create a machine state for IR emulation. 

 Same as [buildState\(false, false, false\)](#buildState(boolean, boolean, boolean))
return: a fresh state

## Method: buildState
- parameter: `initRegisters`, type: `boolean`
- parameter: `initSymbols`, type: `boolean`
- parameter: `initGlobals`, type: `boolean`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.EState`

Description: Create a machine state for IR emulation.
parameter: initRegisters: initialize all global IEVar\-registers to 0
parameter: initSymbols: initialize all global symbols IEVars to 0
parameter: initGlobals: initialize all global memory IEVars to 0
return: a fresh state

## Method: buildState
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.EState`

Description: Create a machine state for IR emulation with all defined registers, symbols, and globals reset to 0. 

 Same as [buildState\(true, true, true\)](#buildState(boolean, boolean, boolean))
return: a fresh state

## Method: canCreateVariable
- parameter: `id`, type: `int`
- parameter: `bitsize`, type: `int`
- return type: `boolean`


## Method: createBranchDetails
- parameter: `def`, type: `java.util.List<com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar>`
- parameter: `use`, type: `java.util.List<com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar>`
- parameter: `spoiled`, type: `java.util.List<com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar>`
- parameter: `fallbackStackPointerDelta`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEBranchDetails`

Description: Create basic branch details information.
parameter: def: 
parameter: use: 
parameter: spoiled: 
parameter: fallbackStackPointerDelta: the provided SP delta will have unknown guarantee and            unknown origin
return: 

## Method: createBranchDetails
- parameter: `def`, type: `java.util.List<com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar>`
- parameter: `use`, type: `java.util.List<com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar>`
- parameter: `spoiled`, type: `java.util.List<com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar>`
- parameter: `fallbackStackPointerDelta`, type: `int`
- parameter: `nativePrototypeHint`, type: `com.pnfsoftware.jeb.core.units.code.asm.type.IPrototypeItem`
- parameter: `dynamicTargetCandidates`, type: `java.util.List<com.pnfsoftware.jeb.core.units.code.asm.analyzer.IBranchTarget>`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEBranchDetails`

Description: Create basic branch details information.
parameter: def: 
parameter: use: 
parameter: spoiled: 
parameter: fallbackStackPointerDelta: 
parameter: nativePrototypeHint: 
parameter: dynamicTargetCandidates: 
return: 

## Method: createCompose
- parameter: `elts`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric[]`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IECompose`

Description: Create a composition of IR elements.
parameter: elts: at least two elements, from lowest\-significant to highest\-significant
return: 

## Method: createCompose
- parameter: `elts`, type: `java.util.Collection<com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric>`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IECompose`


## Method: createCond
- parameter: `p`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- parameter: `a`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- parameter: `b`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IECond`


## Method: createConversionOperation
- parameter: `convOperator`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.OperationType`
- parameter: `src`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- parameter: `dstSize`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEOperation`

Description: Create a conversion operation: an integer truncation, integer extension \(zero or signed\), float truncation or extension, float\-to\-int and int\-to\-float conversion.
parameter: convOperator: one of for which [OperationType#isConversion()](OperationType#isConversion()) returns true \(eg,            [OperationType#CAST](OperationType#CAST), [OperationType#CAST_S](OperationType#CAST_S),            [OperationType#FP2FP](OperationType#FP2FP), [OperationType#FP2INT](OperationType#FP2INT),            [OperationType#INT2FP](OperationType#INT2FP)\)
parameter: src: operand to be extended, truncated, or converted
parameter: dstSize: resulting bitsize
return: the operation IRE

## Method: createFunctionType
- parameter: `name`, type: `java.lang.String`
- parameter: `flags`, type: `int`
- parameter: `opndCount`, type: `int`
- parameter: `resultBitsize`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.FunctionOptype`

Description: Create a new function operation type.
parameter: name: function name \(cannot be blank\)
parameter: flags: function flags, see `FLAG_xxx` in [FunctionOptype](FunctionOptype) for a list of            legal flags
parameter: opndCount: 0\+
parameter: resultBitsize: leave to 0 to signify that the resulting bitsize must be the same as the            first operand's \(in which case minOpndCount must be at least 1\), else a valid            positive bitsize must be specified
return: the function \(never null; this method throws on error\)

## Method: createGlobalReference
- parameter: `name`, type: `java.lang.String`
- parameter: `address`, type: `java.lang.Long`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`

Description: Create or retrieve a variable referencing a global element. Reference variables cannot be assigned to. **The reference is not tracked.**
parameter: name: optional name
parameter: address: optional address referenced \(e.g. if the reference is a concrete data            element\); if the name is null, an address must be specified
return: a reference variable

## Method: createGlobalVariable
- parameter: `address`, type: `long`
- parameter: `bitsize`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`

Description: Create a global, memory\-mapped variable.
parameter: address: 
parameter: bitsize: 
return: 

## Method: createGroupElt
- parameter: `collection`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGroup`
- parameter: `index`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGroupElt`


## Method: createImm
- parameter: `v`, type: `long`
- parameter: `bitsize`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEImm`


## Method: createImm
- parameter: `v`, type: `byte[]`
- parameter: `bitsize`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEImm`


## Method: createImm
- parameter: `v`, type: `java.math.BigInteger`
- parameter: `bitsize`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEImm`


## Method: createImm
- parameter: `v`, type: `java.lang.String`
- parameter: `bitsize`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEImm`


## Method: createImm
- parameter: `v`, type: `float`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEImm`


## Method: createImm
- parameter: `v`, type: `double`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEImm`


## Method: createMem
- parameter: `opaddr`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- parameter: `bitsize`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEMem`


## Method: createMem
- parameter: `segment`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- parameter: `opaddr`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- parameter: `bitsize`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEMem`


## Method: createOperation
- parameter: `optype`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.OperationType`
- parameter: `op1`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEOperation`


## Method: createOperation
- parameter: `optype`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.OperationType`
- parameter: `op1`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- parameter: `op2`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEOperation`


## Method: createOperation
- parameter: `functionOptype`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.FunctionOptype`
- parameter: `opnds`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric[]`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEOperation`


## Method: createRange
- parameter: `begin`, type: `int`
- parameter: `end`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IERange`


## Method: createRegister
- parameter: `id`, type: `int`
- parameter: `name`, type: `java.lang.String`
- parameter: `bitsize`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`

Description: Create a physical register with a manually assigned id \(use with care\). Shared across routines boundaries. No address, no type.
parameter: id: 
parameter: name: 
parameter: bitsize: 
return: 

## Method: createRegister
- parameter: `name`, type: `java.lang.String`
- parameter: `bitsize`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`

Description: Create a physical register. Shared across routines boundaries. No address, no type.
parameter: name: 
parameter: bitsize: 
return: 

## Method: createResizeOperation
- parameter: `opnd`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- parameter: `bitsize`, type: `int`
- parameter: `signed`, type: `boolean`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEOperation`

Description: Create a resize operation operation: truncation, zero\-extension, or sign\-extension.
parameter: opnd: the source to be extended \(dstSize \> srcSize\) or truncated \(dstSize < srcSize\)
parameter: bitsize: the destination size; should be different than the source's
parameter: signed: for extensions, else N/A
return: the operation IRE

## Method: createRoutineContext
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.IERoutineContext`

Description: Create a new routine\-less routine context. The newly created routine context is not attached to this global context. Use [#addRoutineContext(IERoutineContext)](#addRoutineContext(IERoutineContext)) to add it to the global context.
return: 

## Method: createRoutineContext
- parameter: `routine`, type: `com.pnfsoftware.jeb.core.units.code.asm.items.INativeMethodItem`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.IERoutineContext`

Description: Create a new routine context. The newly created routine context is not attached to this global context. Use [#addRoutineContext(IERoutineContext)](#addRoutineContext(IERoutineContext)) to add it to the global context.
parameter: routine: 
return: 

## Method: createSlice
- parameter: `e`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- parameter: `bitstart`, type: `int`
- parameter: `bitend`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IESlice`


## Method: createSlice
- parameter: `e`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEGeneric`
- parameter: `range`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IERange`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IESlice`


## Method: createSymbolForData
- parameter: `data`, type: `com.pnfsoftware.jeb.core.units.code.asm.items.INativeDataItem`
- parameter: `userctx`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.IERoutineContext`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`


## Method: createSymbolForRoutine
- parameter: `routine`, type: `com.pnfsoftware.jeb.core.units.code.asm.items.INativeMethodItem`
- parameter: `userctx`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.IERoutineContext`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`


## Method: createVirtualRegister
- parameter: `id`, type: `int`
- parameter: `name`, type: `java.lang.String`
- parameter: `bitsize`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`

Description: Create a virtual register with a manually assigned id \(use with care\). Preserved/not shared across routines boundaries. No address, no type.
parameter: id: 
parameter: name: 
parameter: bitsize: 
return: 

## Method: createVirtualRegister
- parameter: `name`, type: `java.lang.String`
- parameter: `bitsize`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`

Description: Create a virtual register. Preserved/not shared across routines boundaries. No address, no type.
parameter: name: 
parameter: bitsize: 
return: 

## Method: getAddressBitsize
- return type: `int`


## Method: getAllRegisters
- return type: `java.util.Collection<com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar>`


## Method: getAllRegisters
- parameter: `exclusions`, type: `java.util.Set<java.lang.Integer>`
- return type: `java.util.Collection<com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar>`


## Method: getAllVariables
- return type: `java.util.Collection<com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar>`


## Method: getCandidatePrototype
- parameter: `routine`, type: `com.pnfsoftware.jeb.core.units.code.asm.items.INativeMethodItem`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IWildcardPrototype`


## Method: getConverter
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.AbstractConverter<?>`


## Method: getData
- parameter: `key`, type: `java.lang.Object`
- return type: `java.lang.Object`

Description: Retrieve a piece of transient data.
parameter: key: 
return: 

## Method: getFunctionType
- parameter: `name`, type: `java.lang.String`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.FunctionOptype`

Description: Retrieve a function operation type by name.
parameter: name: function name
return: the function, null if it does not exist \(was not previously created\)

## Method: getGlobalVariable
- parameter: `address`, type: `long`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`


## Method: getGlobalVariables
- return type: `java.util.Collection<com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar>`

Description: Retrieve the list of globals \(memory\) variables defined in this context.
return: 

## Method: getNativeContext
- return type: `com.pnfsoftware.jeb.core.units.code.asm.INativeContext`


## Method: getNativeMemory
- return type: `com.pnfsoftware.jeb.core.units.code.asm.memory.IVirtualMemory`

Description: Convenience method.
return: 

## Method: getObjectTracker
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.INativeObjectTracker`


## Method: getRegisterBitsize
- return type: `int`


## Method: getRoutineContext
- parameter: `index`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.IERoutineContext`


## Method: getRoutineContexts
- return type: `java.util.List<com.pnfsoftware.jeb.core.units.code.asm.decompiler.IERoutineContext>`

Description: Retrieve a list of all converted routines.
return: 

## Method: getVar
- parameter: `id`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`

Description: Retrieve a global context [IEVar](IEVar) by id. Throws if does not exist.
parameter: id: 
return: 

## Method: getVarSafe
- parameter: `id`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`


## Method: getVariableByName
- parameter: `name`, type: `java.lang.String`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`

Description: Retrieve a global\-scope variable by name.
parameter: name: 
return: the variable or null

## Method: getVariables
- parameter: `idStart`, type: `int`
- parameter: `idEnd`, type: `int`
- return type: `java.util.Collection<com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar>`


## Method: getWildcardTypeManager
- return type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IWildcardTypeManager`


## Method: isBigEndian
- return type: `boolean`


## Method: removeRoutineContext
- parameter: `ctx`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.IERoutineContext`
- parameter: `stopTrackingNativeDeps`, type: `boolean`
- return type: `boolean`

Description: Delete a converted routine.
parameter: ctx: 
parameter: stopTrackingNativeDeps: 
return: 

## Method: retrieveDataFromSymbol
- parameter: `var`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.items.INativeDataItem`


## Method: retrieveRoutineFromSymbol
- parameter: `var`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IEVar`
- return type: `com.pnfsoftware.jeb.core.units.code.asm.items.INativeMethodItem`


## Method: setCandidatePrototype
- parameter: `routine`, type: `com.pnfsoftware.jeb.core.units.code.asm.items.INativeMethodItem`
- parameter: `proto`, type: `com.pnfsoftware.jeb.core.units.code.asm.decompiler.ir.IWildcardPrototype`
- parameter: `guarantee`, type: `int`
- return type: `boolean`

Description: 
parameter: routine: 
parameter: proto: 
parameter: guarantee: use 0 for an unknown guarantee
return: 

## Method: setData
- parameter: `key`, type: `java.lang.Object`
- parameter: `value`, type: `java.lang.Object`

Description: Store a piece of transient data.
parameter: key: 
parameter: value: 

