![]() |
Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
|
#include <qqmljscompilepass_p.h>
Public Member Functions | |
const QQmlJSRegisterContent & | accumulatorIn () const |
The accumulatorIn is the input register of the current instruction. | |
const QQmlJSRegisterContent & | accumulatorOut () const |
The accumulatorOut is the output register of the current instruction. | |
void | setRegister (int registerIndex, QQmlJSRegisterContent content) |
void | clearChangedRegister () |
int | changedRegisterIndex () const |
const QQmlJSRegisterContent & | changedRegister () const |
void | addReadRegister (int registerIndex, const QQmlJSRegisterContent ®) |
void | addReadAccumulator (const QQmlJSRegisterContent ®) |
VirtualRegisters | takeReadRegisters () const |
void | setReadRegisters (VirtualRegisters readReagisters) |
QQmlJSRegisterContent | readRegister (int registerIndex) const |
bool | canMoveReadRegister (int registerIndex) const |
bool | isRegisterAffectedBySideEffects (int registerIndex) const |
QQmlJSRegisterContent | readAccumulator () const |
The readAccumulator is the register content expected by the current instruction. | |
bool | readsRegister (int registerIndex) const |
bool | hasSideEffects () const |
void | markSideEffects (bool hasSideEffects) |
void | applySideEffects (bool hasSideEffects) |
void | setHasSideEffects (bool hasSideEffects) |
bool | isRename () const |
void | setIsRename (bool isRename) |
int | renameSourceRegisterIndex () const |
Public Attributes | |
VirtualRegisters | registers |
VirtualRegisters | lookups |
Definition at line 119 of file qqmljscompilepass_p.h.
|
inline |
The accumulatorIn is the input register of the current instruction.
It holds a content, a type that content is acctually stored in, and an enclosing type of the stored type called the scope. Note that passes after the original type propagation may change the type of this register to a different type that the original one can be coerced to. Therefore, when analyzing the same instruction in a later pass, the type may differ from what was seen or requested ealier. See \l {readAccumulator()}. The input type may then need to be converted to the expected type.
Definition at line 135 of file qqmljscompilepass_p.h.
References QQmlJSCompilePass::Accumulator, QFlatMap< Key, T, Compare, KeyContainer, MappedContainer >::end(), QFlatMap< Key, T, Compare, KeyContainer, MappedContainer >::find(), it, Q_ASSERT, and registers.
Referenced by QQmlJSCodeGenerator::generate_As(), QQmlJSTypePropagator::generate_As(), QQmlJSTypePropagator::generate_CmpEqInt(), QQmlJSTypePropagator::generate_CmpNeInt(), QQmlJSTypePropagator::generate_DeadTemporalZoneCheck(), QQmlJSCodeGenerator::generate_Exp(), QQmlJSCodeGenerator::generate_GetIterator(), QQmlJSTypePropagator::generate_GetIterator(), QQmlJSCodeGenerator::generate_GetOptionalLookup(), QQmlJSCodeGenerator::generate_IteratorNext(), QQmlJSTypePropagator::generate_IteratorNext(), QQmlJSCodeGenerator::generate_JumpFalse(), QQmlJSTypePropagator::generate_JumpFalse(), QQmlJSCodeGenerator::generate_JumpTrue(), QQmlJSTypePropagator::generate_JumpTrue(), QQmlJSCodeGenerator::generate_LoadElement(), QQmlJSTypePropagator::generate_LoadElement(), QQmlJSCodeGenerator::generate_Mod(), QQmlJSCodeGenerator::generate_Ret(), QQmlJSTypePropagator::generate_Ret(), QQmlJSCodeGenerator::generate_SetLookup(), QQmlJSCodeGenerator::generate_StoreElement(), QQmlJSTypePropagator::generate_StoreNameCommon(), QQmlJSCodeGenerator::generate_StoreNameSloppy(), QQmlJSTypePropagator::generate_StoreProperty(), QQmlJSCodeGenerator::generate_StoreReg(), QQmlJSTypePropagator::generate_StoreReg(), and QQmlJSCodeGenerator::generate_ThrowException().
|
inline |
The accumulatorOut is the output register of the current instruction.
Definition at line 146 of file qqmljscompilepass_p.h.
References QQmlJSCompilePass::Accumulator, and Q_ASSERT.
Referenced by QQmlJSCodeGenerator::generate_As(), QQmlJSCodeGenerator::generate_CallPropertyLookup(), QQmlJSCodeGenerator::generate_CallQmlContextPropertyLookup(), QQmlJSCodeGenerator::generate_Construct(), QQmlJSCodeGenerator::generate_DefineObjectLiteral(), QQmlJSCodeGenerator::generate_Exp(), QQmlJSCodeGenerator::generate_GetIterator(), QQmlJSCodeGenerator::generate_LoadConst(), QQmlJSCodeGenerator::generate_LoadElement(), QQmlJSCodeGenerator::generate_LoadFalse(), QQmlJSCodeGenerator::generate_LoadGlobalLookup(), QQmlJSCodeGenerator::generate_LoadInt(), QQmlJSTypePropagator::generate_LoadName(), QQmlJSCodeGenerator::generate_LoadNull(), QQmlJSCodeGenerator::generate_LoadQmlContextPropertyLookup(), QQmlJSTypePropagator::generate_LoadQmlContextPropertyLookup(), QQmlJSCodeGenerator::generate_LoadReg(), QQmlJSCodeGenerator::generate_LoadRuntimeString(), QQmlJSCodeGenerator::generate_LoadTrue(), QQmlJSCodeGenerator::generate_LoadUndefined(), QQmlJSCodeGenerator::generate_LoadZero(), QQmlJSCodeGenerator::generate_Mod(), and QQmlJSCodeGenerator::generateEnumLookup().
|
inline |
Definition at line 181 of file qqmljscompilepass_p.h.
References QQmlJSCompilePass::Accumulator, and addReadRegister().
Referenced by QQmlJSTypePropagator::generate_StoreReg().
|
inline |
Definition at line 171 of file qqmljscompilepass_p.h.
References isRename(), Q_ASSERT, and registers.
Referenced by addReadAccumulator(), QQmlJSTypePropagator::generate_LoadReg(), and QQmlJSTypePropagator::generate_MoveReg().
|
inline |
Definition at line 230 of file qqmljscompilepass_p.h.
References QFlatMap< Key, T, Compare, KeyContainer, MappedContainer >::begin(), QFlatMap< Key, T, Compare, KeyContainer, MappedContainer >::end(), hasSideEffects(), it, lookups, and registers.
Referenced by setHasSideEffects().
|
inline |
Definition at line 198 of file qqmljscompilepass_p.h.
References QFlatMap< Key, T, Compare, KeyContainer, MappedContainer >::end(), QFlatMap< Key, T, Compare, KeyContainer, MappedContainer >::find(), and it.
Referenced by QQmlJSCodeGenerator::shouldMoveRegister().
|
inline |
Definition at line 169 of file qqmljscompilepass_p.h.
Referenced by QQmlJSCodeGenerator::changedRegisterVariable(), QQmlJSTypePropagator::endInstruction(), QQmlJSCodeGenerator::generate_ConvertThisToObject(), QQmlJSCodeGenerator::generate_IteratorNext(), QQmlJSCodeGenerator::generate_MoveConst(), QQmlJSCodeGenerator::generate_MoveReg(), QQmlJSCodeGenerator::generate_StoreReg(), QQmlJSCompilePass::nextStateFromAnnotations(), and QQmlJSCodeGenerator::startInstruction().
|
inline |
Definition at line 168 of file qqmljscompilepass_p.h.
Referenced by QQmlJSCodeGenerator::changedRegisterVariable(), QQmlJSTypePropagator::endInstruction(), QQmlJSCodeGenerator::generate_IteratorNext(), QQmlJSCodeGenerator::generate_MoveConst(), QQmlJSCodeGenerator::generate_MoveReg(), QQmlJSCodeGenerator::generate_StoreReg(), QQmlJSCompilePass::nextStateFromAnnotations(), QQmlJSCodeGenerator::startInstruction(), and QQmlJSShadowCheck::startInstruction().
|
inline |
Definition at line 162 of file qqmljscompilepass_p.h.
References QQmlJSCompilePass::InvalidRegister.
Referenced by QQmlJSTypePropagator::endInstruction().
|
inline |
Definition at line 227 of file qqmljscompilepass_p.h.
Referenced by applySideEffects(), QQmlJSTypePropagator::endInstruction(), markSideEffects(), QQmlJSCompilePass::nextStateFromAnnotations(), setHasSideEffects(), QQmlJSCodeGenerator::startInstruction(), and QQmlJSShadowCheck::startInstruction().
|
inline |
Definition at line 204 of file qqmljscompilepass_p.h.
References QFlatMap< Key, T, Compare, KeyContainer, MappedContainer >::end(), QFlatMap< Key, T, Compare, KeyContainer, MappedContainer >::find(), and it.
Referenced by QQmlJSTypePropagator::endInstruction(), QQmlJSCodeGenerator::generate_LoadElement(), and QQmlJSCodeGenerator::generate_StoreElement().
|
inline |
Definition at line 247 of file qqmljscompilepass_p.h.
Referenced by addReadRegister(), QQmlJSTypePropagator::endInstruction(), and setIsRename().
|
inline |
Definition at line 229 of file qqmljscompilepass_p.h.
References hasSideEffects().
Referenced by setHasSideEffects().
|
inline |
The readAccumulator is the register content expected by the current instruction.
It may differ from the actual input type of the accumulatorIn register and usage of the value may require a conversion.
Definition at line 217 of file qqmljscompilepass_p.h.
References QQmlJSCompilePass::Accumulator, and readRegister().
Referenced by QQmlJSCodeGenerator::generate_Exp(), and QQmlJSCodeGenerator::generate_SetLookup().
|
inline |
Definition at line 192 of file qqmljscompilepass_p.h.
References QFlatMap< Key, T, Compare, KeyContainer, MappedContainer >::contains(), and Q_ASSERT.
Referenced by QQmlJSCodeGenerator::generate_As(), QQmlJSCodeGenerator::generate_Construct(), QQmlJSCodeGenerator::generate_DefineObjectLiteral(), QQmlJSCodeGenerator::generate_Exp(), readAccumulator(), and QQmlJSCodeGenerator::shouldMoveRegister().
|
inline |
Definition at line 222 of file qqmljscompilepass_p.h.
References QFlatMap< Key, T, Compare, KeyContainer, MappedContainer >::contains().
Referenced by QQmlJSShadowCheck::generate_GetLookup(), and QQmlJSShadowCheck::generate_LoadProperty().
|
inline |
Definition at line 250 of file qqmljscompilepass_p.h.
References QFlatMap< Key, T, Compare, KeyContainer, MappedContainer >::begin(), Q_ASSERT, and QFlatMap< Key, T, Compare, KeyContainer, MappedContainer >::size().
Referenced by QQmlJSTypePropagator::endInstruction().
|
inline |
Definition at line 242 of file qqmljscompilepass_p.h.
References applySideEffects(), hasSideEffects(), and markSideEffects().
Referenced by QQmlJSTypePropagator::endInstruction(), QQmlJSTypePropagator::generate_CallPossiblyDirectEval(), QQmlJSTypePropagator::generate_CallProperty(), QQmlJSTypePropagator::generate_CallValue(), QQmlJSTypePropagator::generate_CallWithReceiver(), QQmlJSTypePropagator::generate_CallWithSpread(), QQmlJSTypePropagator::generate_CheckException(), QQmlJSTypePropagator::generate_CloneBlockContext(), QQmlJSTypePropagator::generate_Construct(), QQmlJSTypePropagator::generate_ConstructWithSpread(), QQmlJSTypePropagator::generate_CreateCallContext(), QQmlJSTypePropagator::generate_IteratorNext(), QQmlJSTypePropagator::generate_Jump(), QQmlJSTypePropagator::generate_JumpFalse(), QQmlJSTypePropagator::generate_JumpNoException(), QQmlJSTypePropagator::generate_JumpTrue(), QQmlJSTypePropagator::generate_PopContext(), QQmlJSTypePropagator::generate_PopScriptContext(), QQmlJSTypePropagator::generate_PushBlockContext(), QQmlJSTypePropagator::generate_PushCatchContext(), QQmlJSTypePropagator::generate_PushScriptContext(), QQmlJSTypePropagator::generate_PushWithContext(), QQmlJSTypePropagator::generate_Ret(), QQmlJSTypePropagator::generate_SetException(), QQmlJSTypePropagator::generate_SetUnwindHandler(), QQmlJSTypePropagator::generate_StoreElement(), QQmlJSTypePropagator::generate_StoreNameCommon(), QQmlJSTypePropagator::generate_StoreProperty(), QQmlJSTypePropagator::generate_TailCall(), QQmlJSTypePropagator::generate_ThrowException(), QQmlJSTypePropagator::generate_UnwindDispatch(), and QQmlJSTypePropagator::generate_UnwindToLabel().
|
inline |
Definition at line 248 of file qqmljscompilepass_p.h.
References isRename().
Referenced by QQmlJSTypePropagator::endInstruction(), QQmlJSTypePropagator::generate_LoadReg(), QQmlJSTypePropagator::generate_MoveReg(), and QQmlJSTypePropagator::generate_StoreReg().
|
inline |
Definition at line 187 of file qqmljscompilepass_p.h.
Referenced by QQmlJSTypePropagator::endInstruction().
|
inline |
Definition at line 152 of file qqmljscompilepass_p.h.
References QQmlJSRegisterContent::InvalidLookupIndex, lookups, and QQmlJSRegisterContent::resultLookupIndex().
Referenced by QQmlJSTypePropagator::generate_LoadReg(), QQmlJSTypePropagator::generate_MoveReg(), and QQmlJSTypePropagator::generate_StoreReg().
|
inline |
Definition at line 186 of file qqmljscompilepass_p.h.
Referenced by QQmlJSTypePropagator::endInstruction().
VirtualRegisters QQmlJSCompilePass::State::lookups |
Definition at line 122 of file qqmljscompilepass_p.h.
Referenced by applySideEffects(), QQmlJSCodeGenerator::lookupType(), QQmlJSCompilePass::nextStateFromAnnotations(), and setRegister().
VirtualRegisters QQmlJSCompilePass::State::registers |
Definition at line 121 of file qqmljscompilepass_p.h.
Referenced by accumulatorIn(), addReadRegister(), applySideEffects(), QQmlJSTypePropagator::endInstruction(), QQmlJSTypePropagator::generate_CallProperty(), QQmlJSShadowCheck::generate_CallProperty(), QQmlJSShadowCheck::generate_CallPropertyLookup(), QQmlJSTypePropagator::generate_Construct(), QQmlJSShadowCheck::generate_GetLookup(), QQmlJSTypePropagator::generate_LoadElement(), QQmlJSShadowCheck::generate_LoadProperty(), QQmlJSTypePropagator::generate_StoreElement(), QQmlJSTypePropagator::generate_StoreProperty(), QQmlJSCompilePass::initialState(), QQmlJSCompilePass::nextStateFromAnnotations(), QQmlJSCodeGenerator::registerType(), QQmlJSTypePropagator::startInstruction(), and QQmlJSCodeGenerator::startInstruction().