diff options
author | drh <drh@noemail.net> | 2014-02-08 01:40:27 +0000 |
---|---|---|
committer | drh <drh@noemail.net> | 2014-02-08 01:40:27 +0000 |
commit | aceb31b1205c01e933619b05a5f11b0280e2faed (patch) | |
tree | 3503d2ab689ef8186eb3f12dbc6b829ca2b93dac /src/sqliteInt.h | |
parent | 642364a48b21341a5b23ef9b0cc771cba4f2d7c2 (diff) | |
download | sqlite-aceb31b1205c01e933619b05a5f11b0280e2faed.tar.gz sqlite-aceb31b1205c01e933619b05a5f11b0280e2faed.zip |
Change the OP_Trace opcode to OP_Init and give it the ability to jump to the
initialization code at the bottom of the program, thus avoiding the need for
an extra OP_Goto.
FossilOrigin-Name: 192dea97316144f15f6dd0eabff08a0bf9ef203e
Diffstat (limited to 'src/sqliteInt.h')
-rw-r--r-- | src/sqliteInt.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/sqliteInt.h b/src/sqliteInt.h index 45a3986d8..42851ab34 100644 --- a/src/sqliteInt.h +++ b/src/sqliteInt.h @@ -1088,8 +1088,7 @@ struct sqlite3 { ** Return true if it OK to factor constant expressions into the initialization ** code. The argument is a Parse object for the code generator. */ -#define ConstFactorOk(P) \ - ((P)->cookieGoto>0 && OptimizationEnabled((P)->db,SQLITE_FactorOutConst)) +#define ConstFactorOk(P) ((P)->okConstFactor) /* ** Possible values for the sqlite.magic field. @@ -2354,6 +2353,7 @@ struct Parse { u8 isMultiWrite; /* True if statement may modify/insert multiple rows */ u8 mayAbort; /* True if statement may throw an ABORT exception */ u8 hasCompound; /* Need to invoke convertCompoundSelectToSubquery() */ + u8 okConstFactor; /* OK to factor out constants */ int aTempReg[8]; /* Holding area for temporary registers */ int nRangeReg; /* Size of the temporary register block */ int iRangeReg; /* First register in temporary register block */ @@ -2382,7 +2382,6 @@ struct Parse { Token constraintName;/* Name of the constraint currently being parsed */ yDbMask writeMask; /* Start a write transaction on these databases */ yDbMask cookieMask; /* Bitmask of schema verified databases */ - int cookieGoto; /* Address of OP_Goto to cookie verifier subroutine */ int cookieValue[SQLITE_MAX_ATTACHED+2]; /* Values of cookies to verify */ int regRowid; /* Register holding rowid of CREATE TABLE entry */ int regRoot; /* Register holding root page number for new objects */ |