Commit graph

308 commits

Author SHA1 Message Date
Pekka Enberg
8ce67768e3 core: Move where_clause.rs to translate/ 2024-07-21 20:36:56 +03:00
Pekka Enberg
fee1530ea6 core: Move expr.rs to translate/ 2024-07-21 20:36:56 +03:00
Joan Martinez
6ff27454cc Merge branch 'main' of https://github.com/JoanFM/limbo into fix-io-arc 2024-07-21 19:31:27 +02:00
Joan Martinez
642603b6c7 perf-latency: fix enabling to build multitenancy 2024-07-21 19:13:02 +02:00
Joan Martinez
4bcae54aa9 fix: use Arc to handle IO 2024-07-21 19:01:58 +02:00
Bennett Clement
2e0d4c6fdb Implement basic ORDER BY
- Only SELECT * is supported
- Only ASC is supported
2024-07-22 00:28:00 +08:00
jussisaurio
dcd08e3b38 Extract modules expr,select,where_clause from translate.rs 2024-07-18 14:31:26 +03:00
Raminder Singh
e4a9c5ce6e fix clippy warnings 2024-07-14 16:50:54 +05:30
Kunal Singh
00c26286ce fix: lint warnings 2024-07-08 22:43:11 +05:30
Piotr Jastrzebski
c01f39aefb Make it possible to get row values as &str
This allows to avoid some unneeded copies and allocations.

Signed-off-by: Piotr Jastrzebski <haaawk@gmail.com>
2024-07-07 18:51:47 +02:00
Pekka Enberg
30ec86a81e Add sorter utility functions and opcodes
This adds basic in-memory sorting utility functions, similar to SQLite's
src/vdbesort.c. We need to improve this later with external sorting so
to support large data sets.

This also adds sorting functionality to the VDBE. Note that none of this
is wired to SQL translation yet so it's unused for now.
2024-07-07 13:56:55 +03:00
Piotr Jastrzebski
7b6c6ef9f1 Remove unneeded clone in add_table
Signed-off-by: Piotr Jastrzebski <haaawk@gmail.com>
2024-07-07 08:47:47 +02:00
Pekka Enberg
e988ca0129 Consolidate AggregateFunction and AggFunc enums 2024-07-04 12:19:17 +03:00
Pekka Enberg
307fed0848 Format source code with cargo fmt 2024-07-03 11:38:12 +03:00
Pere Diaz Bou
9242e5c671 core: fix agg function uppercase parsing
Signed-off-by: Pere Diaz Bou <pere-altea@hotmail.com>
2024-07-03 08:56:30 +02:00
Pere Diaz Bou
427103b199 core,wasm: add missing write procedure to wasm 2024-06-19 20:54:55 +02:00
Pere Diaz Bou
932ae7bf3f core: update pragma in transalte 2024-06-19 20:37:17 +02:00
Pere Diaz Bou
7e03cc70d0 core: add minimum cache_size 2024-06-19 20:37:17 +02:00
Pere Diaz Bou
1884aab3b8 core: resize page cache
Abstract page cache with PageCache so that we can call resize inside
refcell
2024-06-19 20:37:17 +02:00
Pere Diaz Bou
53c348402a core: parse unary and write to disk 2024-06-19 20:37:15 +02:00
Pere Diaz Bou
d795a7a3ba core: introduce pseudo program with pragma
Introduced pragma statement parsing and update in memory of default page cache size.

There are some more "improvements" to the print insn procedure —  I couldn't decide what was the preferred way in rust to do printing on different int types so I went with the stupidest I could think of at the moment.
2024-06-19 20:32:21 +02:00
Pekka Enberg
042e5476f1 Fix source formatting with cargo fmt 2024-05-08 07:18:22 -03:00
Pekka Enberg
5ebf51ae5a Add tracing to prepare() and query() 2024-05-07 06:38:13 -03:00
Pekka Enberg
88f335db16 Fix SQL identifiers to be case insensitive
SQLite seems to treat everything as case insensitive so let's do that
too.

Fixes #37
2024-03-27 21:00:47 +02:00
Pekka Enberg
ed9f3e6d1e Single-threaded architecture
Use Rc instead of Arc and replace the concurrent LRU with
single-threaded SIEVE.

Fixes #23
Fixes #29
2024-03-03 12:44:45 +02:00
Pekka Enberg
9f733b5a73 Simplify Statement::step() 2024-01-28 10:20:45 +02:00
Pekka Enberg
64213766a2 Remove redundant lifetime parameter from Statement::step() 2024-01-28 10:19:31 +02:00
Pekka Enberg
d5bceaefdb Remove redundant loop from Statement::step() 2024-01-28 10:18:59 +02:00
Pekka Enberg
505e28aaeb Reduce memory allocations
Fixes #26
2024-01-28 09:57:12 +02:00
Pekka Enberg
0b9b6cfd29 Asynchronous I/O 2024-01-24 08:14:53 +02:00
Pekka Enberg
44dcd48071 Fix WebAssembly build 2024-01-14 15:29:27 +02:00
Pekka Enberg
ae2f403838 core: Fix step() return path when page is under I/O 2024-01-12 17:35:55 +02:00
Pekka Enberg
2267ee121b Introduce Completion type 2023-11-09 21:11:48 +02:00
Pekka Enberg
76d16cb506 Fix I/O module compilation on wasm target 2023-10-24 19:05:34 +03:00
Pekka Enberg
dad0b6d627 Disable mimalloc for wasm target 2023-10-24 19:01:22 +03:00
Pekka Enberg
de6f327a4a Move raw buffer to I/O module 2023-09-30 14:19:55 +03:00
Pekka Enberg
1e1e096a48 Refactor I/O and storage layers 2023-09-16 09:34:17 +03:00
Pekka Enberg
b49c242266 Rename PageSource to File 2023-09-10 22:01:45 +03:00
Pekka Enberg
fe41f46bc0 I/O trait 2023-09-10 21:57:36 +03:00
Pekka Enberg
e38c816ee8 Move translate() into its own file 2023-09-10 12:37:17 +03:00
Pekka Enberg
4a5c71ab7a I/O interface refactoring 2023-09-09 10:22:26 +03:00
Pekka Enberg
49c19b55ab Unify sync I/O 2023-09-08 20:27:32 +03:00
Pekka Enberg
ccee8c3336 Parse schema from database file
Fixes #1
2023-09-02 19:19:23 +03:00
Pekka Enberg
65d1d770b3 Switch to mimalloc
...it's faster.
2023-09-02 14:04:22 +03:00
Pekka Enberg
37baae3ed7 Benchmark 2023-09-02 13:43:07 +03:00
Pekka Enberg
60376ed3dd Fix EXPLAIN when querying 2023-09-02 11:42:17 +03:00
Pekka Enberg
3ec9c0be7c Implement ResultRow opcode 2023-09-02 11:40:11 +03:00
Pekka Enberg
6e748a066e Register allocation 2023-09-02 08:52:30 +03:00
Pekka Enberg
4c64590a5c Decouple Program and ProgramState 2023-09-02 08:18:05 +03:00
Pekka Enberg
591e8df377 Disable tracing by default 2023-09-01 19:49:54 +03:00