SQLite

Check-in [90f4cf2ad5]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Add hooks for the SSE extension. (CVS 2449)
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 90f4cf2ad57309dbd20954fc7fd60859bc44bcf4
User & Date: drh 2005-04-28 19:03:37.000
Context
2005-04-29
02:10
Prevent a segfault described by ticket #1229. (CVS 2450) (check-in: 0667eae9a9 user: drh tags: trunk)
2005-04-28
19:03
Add hooks for the SSE extension. (CVS 2449) (check-in: 90f4cf2ad5 user: drh tags: trunk)
17:18
Enhancements to allow for extensions. (CVS 2448) (check-in: 6863703abc user: drh tags: trunk)
Changes
Side-by-Side Diff Ignore Whitespace Patch
Changes to src/pragma.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14

15
16
17
18
19
20
21
1
2
3
4
5
6
7
8
9
10
11
12
13

14
15
16
17
18
19
20
21













-
+







/*
** 2003 April 6
**
** The author disclaims copyright to this source code.  In place of
** a legal notice, here is a blessing:
**
**    May you do good and not evil.
**    May you find forgiveness for yourself and forgive others.
**    May you share freely, never taking more than you give.
**
*************************************************************************
** This file contains code used to implement the PRAGMA command.
**
** $Id: pragma.c,v 1.91 2005/03/29 03:10:59 danielk1977 Exp $
** $Id: pragma.c,v 1.92 2005/04/28 19:03:37 drh Exp $
*/
#include "sqliteInt.h"
#include "os.h"
#include <ctype.h>

/* Ignore this whole file if pragmas are disabled
*/
900
901
902
903
904
905
906











907
908
909
910
911
912
913
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924







+
+
+
+
+
+
+
+
+
+
+







        sqlite3VdbeOp3(v, OP_String, 0, 0, 
            (j>=0 && j<=4) ? azLockName[j] : "unknown", P3_STATIC);
      }
      sqlite3VdbeAddOp(v, OP_Callback, 2, 0);
    }
  }else
#endif

#ifdef SQLITE_SSE
  /*
  ** Check to see if the sqlite_statements table exists.  Create it
  ** if it does not.
  */
  if( sqlite3StrICmp(zLeft, "create_sqlite_statement_table")==0 ){
    extern int sqlite3CreateStatementsTable(sqlite3*);
    sqlite3CreateStatementsTable(db);
  }else
#endif

  {}

  if( v ){
    /* Code an OP_Expire at the end of each PRAGMA program to cause
    ** the VDBE implementing the pragma to expire. Most (all?) pragmas
    ** are only valid for a single execution.
Changes to src/tclsqlite.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14

15
16
17
18
19
20
21
1
2
3
4
5
6
7
8
9
10
11
12
13

14
15
16
17
18
19
20
21













-
+







/*
** 2001 September 15
**
** The author disclaims copyright to this source code.  In place of
** a legal notice, here is a blessing:
**
**    May you do good and not evil.
**    May you find forgiveness for yourself and forgive others.
**    May you share freely, never taking more than you give.
**
*************************************************************************
** A TCL Interface to SQLite
**
** $Id: tclsqlite.c,v 1.122 2005/04/28 17:18:49 drh Exp $
** $Id: tclsqlite.c,v 1.123 2005/04/28 19:03:37 drh Exp $
*/
#ifndef NO_TCL     /* Omit this whole file if TCL is unavailable */

#include "sqliteInt.h"
#include "hash.h"
#include "tcl.h"
#include <stdlib.h>
1775
1776
1777
1778
1779
1780
1781
1782

1783
1784
1785
1786
1787
1788
1789
1775
1776
1777
1778
1779
1780
1781

1782
1783
1784
1785
1786
1787
1788
1789







-
+








    Sqlitetest1_Init(interp);
    Sqlitetest2_Init(interp);
    Sqlitetest3_Init(interp);
    Sqlitetest4_Init(interp);
    Sqlitetest5_Init(interp);
    Md5_Init(interp);
#ifdef SQLITE_TEST_SSE
#ifdef SQLITE_SSE
    Sqlitetestsse_Init(interp);
#endif
  }
#endif
  if( argc>=2 || TCLSH==2 ){
    int i;
    Tcl_SetVar(interp,"argv0",argv[1],TCL_GLOBAL_ONLY);
Changes to src/vacuum.c.
10
11
12
13
14
15
16
17

18
19
20
21
22
23
24
10
11
12
13
14
15
16

17
18
19
20
21
22
23
24







-
+







**
*************************************************************************
** This file contains code used to implement the VACUUM command.
**
** Most of the code in this file may be omitted by defining the
** SQLITE_OMIT_VACUUM macro.
**
** $Id: vacuum.c,v 1.40 2005/02/16 03:27:05 drh Exp $
** $Id: vacuum.c,v 1.41 2005/04/28 19:03:37 drh Exp $
*/
#include "sqliteInt.h"
#include "os.h"

#ifndef SQLITE_OMIT_VACUUM
/*
** Generate a random name of 20 character in length.
292
293
294
295
296
297
298











299
300
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311







+
+
+
+
+
+
+
+
+
+
+


  if( zTemp ){
    sqlite3OsDelete(zTemp);
    sqliteFree(zTemp);
  }
  if( zSql ) sqliteFree( zSql );
  sqlite3ResetInternalSchema(db, 0);
#endif

#ifdef SQLITE_SSE
  /* If the SSE extension is compiled in, recompile all statements
  ** in the sqlite_statements table after a successful VACUUM
  */
  if( rc==SQLITE_OK ){
    extern int sqlite3RecompileStatements(sqlite3*);
    rc = sqlite3RecompileStatements(db);
  }
#endif /* SQLITE_SSE */

  return rc;
}