SQLite

Changes On Branch better-comment
Login

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

Changes In Branch better-comment Excluding Merge-Ins

This is equivalent to a diff from 3daab949 to 6f2fb60e

2021-05-19
19:28
Add a comment with useful information about SHM locking. No changes to deliverable code. (check-in: 4e81ea3b user: drh tags: trunk)
19:27
Fix a formatting error on the comment. (Closed-Leaf check-in: 6f2fb60e user: drh tags: better-comment)
16:55
Add a table of shared-memory lock offsets in a comment in the os_unix.c code. Include some assert()s to help verify the numbers. (check-in: b480aacb user: drh tags: better-comment)
14:49
Allow aggregate sub-selects within ORDER BY and PARTITION BY clauses of window frame definitions. (check-in: 3daab949 user: dan tags: trunk)
12:17
Improved column name and column type determination for the RETURNING clause. (check-in: 699c3399 user: drh tags: trunk)

Changes to src/os_unix.c.

8063
8064
8065
8066
8067
8068
8069
















8070
8071
8072
8073
8074
8075
8076
  assert( ArraySize(aSyscall)==29 );

  /* Register all VFSes defined in the aVfs[] array */
  for(i=0; i<(sizeof(aVfs)/sizeof(sqlite3_vfs)); i++){
    sqlite3_vfs_register(&aVfs[i], i==0);
  }
  unixBigLock = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_VFS1);
















  return SQLITE_OK; 
}

/*
** Shutdown the operating system interface.
**
** Some operating systems might need to do some cleanup in this routine,







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







8063
8064
8065
8066
8067
8068
8069
8070
8071
8072
8073
8074
8075
8076
8077
8078
8079
8080
8081
8082
8083
8084
8085
8086
8087
8088
8089
8090
8091
8092
  assert( ArraySize(aSyscall)==29 );

  /* Register all VFSes defined in the aVfs[] array */
  for(i=0; i<(sizeof(aVfs)/sizeof(sqlite3_vfs)); i++){
    sqlite3_vfs_register(&aVfs[i], i==0);
  }
  unixBigLock = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_VFS1);

  /* Validate lock assumptions */
  assert( SQLITE_SHM_NLOCK==8 );  /* Number of available locks */
  assert( UNIX_SHM_BASE==120  );  /* Start of locking area */
  /* Locks:
  **    WRITE       UNIX_SHM_BASE      120
  **    CKPT        UNIX_SHM_BASE+1    121
  **    RECOVER     UNIX_SHM_BASE+2    122
  **    READ-0      UNIX_SHM_BASE+3    123
  **    READ-1      UNIX_SHM_BASE+4    124
  **    READ-2      UNIX_SHM_BASE+5    125
  **    READ-3      UNIX_SHM_BASE+6    126
  **    READ-4      UNIX_SHM_BASE+7    127
  **    DMS         UNIX_SHM_BASE+8    128
  */
  assert( UNIX_SHM_DMS==128   );  /* Byte offset of the deadman-switch */
  return SQLITE_OK; 
}

/*
** Shutdown the operating system interface.
**
** Some operating systems might need to do some cleanup in this routine,