Commit graph

1600 commits

Author SHA1 Message Date
Micha Reiser
632faff5a6
Implement inputs builder 2024-08-06 08:44:12 +02:00
Micha Reiser
d6df21fba1
Merge pull request #557 from MichaReiser/high-durability-write
Some checks are pending
Book / Book (push) Waiting to run
Book / Deploy (push) Blocked by required conditions
Test / Test (false, beta) (push) Waiting to run
Test / Test (false, stable) (push) Waiting to run
Test / Test (true, nightly) (push) Waiting to run
Test / Miri (push) Waiting to run
Test / Benchmarks (push) Waiting to run
Fix query invalidation when high durability input changes
2024-08-05 16:36:21 +00:00
Niko Matsakis
c830be20f2
Merge pull request #549 from obsgolem/fix_warning
Fixed non_local_definitions warning
2024-08-05 16:36:16 +00:00
Carl Meyer
2979ef5ce7
Merge pull request #544 from carljm/test-log
Add test tracing, fix up comments
2024-08-05 16:34:40 +00:00
Niko Matsakis
973527b620
Merge pull request #551 from carljm/clippy
Add -D warnings to clippy CI
2024-08-05 16:33:14 +00:00
Niko Matsakis
ed576fed25
Merge pull request #556 from gvozdvmozgu/boomphf
remove unused `boomphf` dependency
2024-08-05 16:17:41 +00:00
Carl Meyer
00adc13e89
Add clippy -D warnings to CI 2024-08-05 08:38:56 -07:00
Carl Meyer
56e29b554d
Add test tracing, fix up comments 2024-08-05 08:34:59 -07:00
Micha Reiser
a263dd04ba
Fix query invalidation when high durability input changes 2024-08-05 16:24:39 +02:00
Andrey Nikolaev
ea05d74a90 remove unused boomphf dependency 2024-08-05 11:17:15 +00:00
Niko Matsakis
994c988739
Merge pull request #552 from carljm/debug-stamps
Some checks are pending
Book / Book (push) Waiting to run
Book / Deploy (push) Blocked by required conditions
Test / Test (false, beta) (push) Waiting to run
Test / Test (false, stable) (push) Waiting to run
Test / Test (true, nightly) (push) Waiting to run
Test / Miri (push) Waiting to run
Test / Benchmarks (push) Waiting to run
Require Debug for C::Stamps
2024-08-05 07:34:35 +00:00
Niko Matsakis
7bdf51cde2
Merge pull request #538 from nikomatsakis/spindle2
Some checks are pending
Book / Book (push) Waiting to run
Book / Deploy (push) Blocked by required conditions
Test / Test (false, beta) (push) Waiting to run
Test / Test (false, stable) (push) Waiting to run
Test / Test (true, nightly) (push) Waiting to run
Test / Miri (push) Waiting to run
Test / Benchmarks (push) Waiting to run
New database design
2024-08-04 08:26:45 +00:00
Niko Matsakis
1bce41f5d6 stop ignoring miri
Fixes #520
2024-08-04 04:21:06 -04:00
Niko Matsakis
6ff1975e17 Update components/salsa-macro-rules/src/setup_input_struct.rs
Co-authored-by: Micha Reiser <micha@reiser.io>
2024-08-04 03:05:32 -04:00
Niko Matsakis
118e89ce20 add ingredient_debug_name API 2024-08-04 03:02:28 -04:00
Niko Matsakis
83be1e4877 make the Views type miri-safe
and add more comments
2024-08-04 02:29:16 -04:00
Niko Matsakis
bca9180e05 just cache the index 2024-08-04 02:29:07 -04:00
Niko Matsakis
9f95b37af9 add a justfile for convenience
This should really be synchronized with the
codespaces and github configuration but...
I'm not clever enough to do all that.
2024-08-04 02:23:10 -04:00
Niko Matsakis
cafbe9247b update debug output 2024-08-04 02:22:27 -04:00
Niko Matsakis
4d2ccffddc return to the database-wrapping-storage setup 2024-08-04 02:18:54 -04:00
Carl Meyer
b8ab0f8ba4
Require Debug for C::Stamps 2024-08-02 13:45:04 -07:00
Josiah Bills
49657a4989 Fixed non_local_definitions warning. 2024-08-01 20:09:13 -04:00
Carl Meyer
f65bfe1855
Update expect test output 2024-07-29 19:01:54 -07:00
Micha Reiser
12e0741252
Implement DerefMut 2024-07-29 10:25:26 +02:00
Micha Reiser
4995ce0ddc
Relax dependency constraints 2024-07-29 09:58:57 +02:00
Niko Matsakis
502716d368 pacify the merciless cargo fmt 2024-07-28 21:33:05 +00:00
Niko Matsakis
ab112b7126 rename local_state to zalsa_local 2024-07-28 13:12:58 +00:00
Niko Matsakis
3254f46ca8 rename LocalState to ZalsaLocal 2024-07-28 13:12:31 +00:00
Niko Matsakis
9054377546 rename storage mod to zalsa 2024-07-28 13:11:57 +00:00
Niko Matsakis
d141cd8500 encapsulate Runtime within Zalsa
The aim is to eventually eliminate Runtime.
2024-07-28 13:10:29 +00:00
Niko Matsakis
703e12def8 remove the Zalsa trait and make it a struct 2024-07-28 13:06:30 +00:00
Niko Matsakis
34e109d390 remove type parameter from ZalsaImpl 2024-07-28 13:01:09 +00:00
Niko Matsakis
85628247e5 pacify the merciless clippy 2024-07-28 12:47:50 +00:00
Niko Matsakis
f8b1620ca7 pacify the merciless cargo fmt 2024-07-28 12:47:50 +00:00
Niko Matsakis
a675810edf move local-state into DatabaseImpl
Each clone gets an independent local state.
2024-07-28 12:47:50 +00:00
Niko Matsakis
8e9ebbafd3 improve comments 2024-07-28 12:47:50 +00:00
Niko Matsakis
138ca4b1f3 merge handle into the database
Separate handles are no longer needed.
2024-07-28 12:47:50 +00:00
Niko Matsakis
62f158742c rename Storage to ZalsaImpl, privatize 2024-07-28 12:47:50 +00:00
Niko Matsakis
daaa78056a switch to new database design
Under this design, *all* databases are a
`DatabaseImpl<U>`, where the `U` implements
`UserData` (you can use `()` if there is none).

Code would default to `&dyn salsa::Database` but
if you want to give access to the userdata, you
can define a custom database trait
`MyDatabase: salsa::Databse` so long as you

* annotate `MyDatabase` trait definition of
  impls of `MyDatabase` with `#[salsa::db]`
* implement `MyDatabase` for `DatabaseImpl<U>`
  where `U` is your userdata (this could be a
  blanket impl, if you don't know the precise
  userdata type).

The `tests/common/mod.rs` shows the pattern.
2024-07-28 12:47:50 +00:00
Niko Matsakis
64556e9d28 make event generation lazy
Creating events if nobody is listening has
always bugged me.
2024-07-28 12:35:33 +00:00
Niko Matsakis
1842b1dfbb (almost) encansulate Runtime into Zalsa
The distinction is dumb and should go away.
But we still need it for a bit.
2024-07-28 12:35:33 +00:00
Niko Matsakis
596461c213 hide internal methods behind a Zalsa trait
The traits are now quite simple:

* Database is the external trait
* ZalsaDatabase is the internal one, implemented
  by `#[salsa::db]`. It adds two methods,
  `zalsa` and `zalsa_mut`. Those give access
  to our internal methods.

For now I've hidden the methods behind
`&dyn Zalsa`. This is nice and clean but it may
be worth later refactoring to a `struct Zalsa`.
2024-07-28 12:35:33 +00:00
Niko Matsakis
bc72bdf524 as_salsa_database => as_dyn_database
Also, move to a blanket impl'd trait.
Overall cleaner approach.
2024-07-28 12:35:33 +00:00
Niko Matsakis
9e8635c7db remove upcast_mut
We only ever need to upcast to shared references.

This change isn't necessary, just dead code
cleanup.
2024-07-28 12:35:33 +00:00
Niko Matsakis
cd339fc1c9
Merge pull request #542 from nikomatsakis/codspeed
Some checks failed
Book / Book (push) Has been cancelled
Test / Test (false, beta) (push) Has been cancelled
Test / Test (false, stable) (push) Has been cancelled
Test / Test (true, nightly) (push) Has been cancelled
Test / Miri (push) Has been cancelled
Test / Benchmarks (push) Has been cancelled
Book / Deploy (push) Has been cancelled
Merge Codspeed
2024-07-28 11:09:37 +00:00
Niko Matsakis
581513302a Merge remote-tracking branch 'salsa-rs/add-codspeed' 2024-07-28 11:07:09 +00:00
Niko Matsakis
b37a821d97
Merge pull request #541 from nikomatsakis/upgrade-dependencies
upgrade all the things
2024-07-28 10:42:48 +00:00
Niko Matsakis
c50cefa71e upgrade all the things 2024-07-28 10:38:30 +00:00
Niko Matsakis
33889889e8
Merge pull request #540 from nikomatsakis/codespaces-config
basic GitHub codespaces configuration
2024-07-28 10:18:01 +00:00
Niko Matsakis
d0a105a193 devcontainer definition
Created by VSCode's command.
2024-07-28 10:16:36 +00:00