Skip to content
This repository has been archived by the owner on Mar 20, 2024. It is now read-only.

[Bug] Handle mutexes and probably atomics #320

Closed
ksolana opened this issue Sep 2, 2023 · 2 comments
Closed

[Bug] Handle mutexes and probably atomics #320

ksolana opened this issue Sep 2, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@ksolana
Copy link
Collaborator

ksolana commented Sep 2, 2023

See: aptos-move/move-examples/defi/sources/locked_coins.move

EBPF documentation on atomics: https://www.kernel.org/doc/html/latest/bpf/instruction-set.html#atomic-operations

@ksolana ksolana added the bug Something isn't working label Sep 2, 2023
@ksolana ksolana changed the title [Bug] Handle atomics [Bug] Handle mutexes and probably atomics Sep 2, 2023
@brson
Copy link
Collaborator

brson commented Sep 4, 2023

I think that the locks in the referenced example are not machine-level locks, but instead logical locks on when and who are allowed to withdraw funds from a contract.

As far as I know, any machine-level concurrency between move transactions are handled in a way similar to solana - by analyzing the data dependencies between them and executing them in an order that does not produce concurrent mutations.

Move code will probably not need atomics.

@ksolana
Copy link
Collaborator Author

ksolana commented Sep 12, 2023

not required.

@ksolana ksolana closed this as completed Sep 12, 2023
@ksolana ksolana closed this as not planned Won't fix, can't repro, duplicate, stale Sep 12, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants