Comments (7)
While the MSRV of crossbeam is lower than 1.60.0, it should be possible to use the hard coded list as fallback when the rustc version is too old for stable
cfg(target_has_atomic)
.
This is an approach I have previously explicitly stated I accept and would accept a PR that implements this.
#937 (comment)
from crossbeam.
cc rust-lang/rust#117170 (comment)
from crossbeam.
Do you know how to handle cfg(not(crossbeam_no_atomic_cas))
? Use cfg(target_has_atomic="ptr")
?
from crossbeam.
Use
cfg(target_has_atomic="ptr")
?
Yes.
not(crossbeam_no_atomic_cas)
corresponds totarget_has_atomic = "ptr"
.not(crossbeam_no_atomic_64)
(almost) corresponds totarget_has_atomic = "64"
. (To be precise, it is closer to unstabletarget_has_atomic_load_store = "64"
, but currently, the only time the two would actually have different meanings is when using a custom no-std target.)not(crossbeam_no_atomic)
(almost) corresponds to unstabletarget_has_atomic_load_store = "ptr"
. There is no stable alternative to this, so I think this may require continuing to use our own cfg. This cfg only affects some no-std targets.
from crossbeam.
Is adding autocfg as build dependency to the crates that don't have it yet fine?
from crossbeam.
Yeah, it's fine.
That said, given that #1015 will increase MSRV to 1.59, it would also actually be fine to increase MSRV to 1.60 or 1.61 and remove the need for build scripts. (I had forgotten about that PR when I first commented in this issue.)
from crossbeam.
I think I will wait for that PR.
from crossbeam.
Related Issues (20)
- Can we avoid to call `try_advance` in some senarios? [crossbeam-epoch] HOT 2
- Epoch memory reclamation algorithm HOT 2
- consider adding `is_disconnected` method to Receiver type HOT 1
- Scaling receiver counter up/down based on demand
- `select!` macro and auto-complete HOT 1
- [crossbeam-epoch] false sharing issue for "epoch: AtomicEpoch" field in "Local" struct
- crossbeam-skiplist bug HOT 3
- epoch `fetch_update` not working as expected HOT 2
- Crossbeam channel slower than Go channels with input data delay HOT 5
- Questions about "crossbeam_epoch" HOT 10
- crossbeam channel is very slow if restricted to a single core HOT 4
- Donating Funds to Crossbeam HOT 1
- Publish new `crossbeam-epoch` with updated `memoffset` HOT 2
- crossbeam_channel::tick delivery_time can support different flavor HOT 4
- what shuld used for AtomicCell or ShardedLock HOT 1
- Cirrus CI no longer supports 32-bit mode on ARM Linux runners
- Always use load(Acquire) for load_consume on Miri/TSan
- Question (epoch): How to avoid Miri to report data race on an `Atomic` pointer? HOT 6
- crossbeam::channel::Receiver::try_recv can block forever if sending thread is blocked HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from crossbeam.