HN user

dreamingincode

238 karma
Posts16
Comments15
View on HN
www.completeskeptic.com 17d ago

Scaling Laws, Honestly

dreamingincode
3pts0
www.pnas.org 4mo ago

Bacterial biofilms are intrinsic components of calcium-based kidney stones

dreamingincode
2pts0
github.com 1y ago

Access to GitHub restricted for (part of) mainland China

dreamingincode
24pts4
nypost.com 1y ago

Apple threatened to move Will Smith movie out of Louisiana for app store bill

dreamingincode
35pts12
github.com 2y ago

Show HN: Material Files – Open Source Material Design File Manager for Android

dreamingincode
163pts71
t.bilibili.com 2y ago

LK-99 crystal verified to be magnetically levitated (with video)

dreamingincode
70pts13
forums.aws.amazon.com 5y ago

AWS Developer Forums: S3 Block Devices

dreamingincode
22pts5
www.bbc.com 5y ago

The dead professor and the vast pro-India disinformation campaign

dreamingincode
3pts0
www.bbc.com 6y ago

Kashmir blackout eases but restrictions remain

dreamingincode
2pts0
arstechnica.com 6y ago

Indian Supreme Court finds 150-day Internet blackout in Kashmir illegal

dreamingincode
1pts0
www.eveonline.com 6y ago

Keepstar destoryed in M-OEE8 in the largest battle in EVE Online (2017)

dreamingincode
1pts0
android.googlesource.com 8y ago

Choice of search engine on Android nuked by “Anonymous Coward” (2009)

dreamingincode
265pts78
github.com 9y ago

Minimal solar system model with OpenGL in C

dreamingincode
4pts0
joshworth.com 9y ago

If the Moon Were Only 1 Pixel

dreamingincode
2pts0
stackoverflow.com 10y ago

They removed part of the ripple effect in Android Marshmallow

dreamingincode
1pts0
twitter.com 11y ago

UEFI backdoor allows root exploit in Linux

dreamingincode
3pts0

It does, it's called DocumentsUI and provides the system file picker. However its main entry point is often hidden, and imo it's still somewhat suboptimal/limited in certain aspects. But it's the only way to access the private Android/data directory right now.

Material Files also provides the ability to easily open DocumentsUI for browsing Android/data.

Material Files also allows you add a shortcut to the stock file manager (DocumentsUI), using "Add storage" > "Android/data" from app drawer. You may even manually edit the shortcut to point to a specific subdirectory inside Android/data, and I plan to make that easier (so that you don't need to manually URI-encode your path if you edit) in an upcoming version.

Under the guidance of Professor Haixin Chang, postdoctor Hao Wu and PhD student Li Yang from the School of Materials Science and Technology of Huazhong University of Science and Technology successfully for the first time verified the LK-99 crystal that can be magnetically levitated with larger levitated angle than Sukbae Lee‘s sample at room temperature. It is expected to realize the true potential of room temperature, non-contact superconducting magnetic levitation.

AI translated video: https://targum.video/v/2023/8/1/e2ad3b8e86961ccfdcf411d2d4d1...

Original video: https://www.bilibili.com/video/BV14p4y1V7kS

I see. It seems sometimes we do have to live with non-deterministic behaviors or even small errors.

I'm still unsure about the following question from your answers: > when some kind of mechanism mutates two entities in different chunks, which thread is chosen to run this mutation? And how does it mutate the state for the entity in the other chunk? My initial thought was this would require adding locking on every entity, since it might be accessed from another chunk/thread. But that's clearly not ideal. Maybe have a separate list for outside-chunk changes, and merge them with internal changes later?

And regarding having two states: How/when are you sending world state to clients? My thought was to clone the current state periodically and send it to clients (can sending takes less than one tick? I don't have an idea). Sending state to clients seems to be needed if the game needs client side predication, hence this question.

Thanks! The idea of having a list of migrating entities per chunk is good, and it avoids locking on the list of all entities in a chunk. But I still have some confusion about it:

The server looks up the destination in the "active chunk set" I mentioned

but what if the entity teleports to an inactive chunk?

and then uses per-chunk std::vector<>s guarded by a mutex to push "migrating" entities.

Will these migrating entities participate in later calculation within the same tick, or are they excluded? If excluded, what happens when there are two mechanisms that mutates that entity, but the first one put it into the migrating list of another chunk? If included, the thread of which chunk will continue this calculation?

And when some kind of mechanism mutates two entities in different chunks, which thread is chosen to run this mutation? And how does it mutate the state for an entity in the other chunk?

Meanwhile since you mentioned ticks, (just to be sure) are you using a barrier per tick to wait for all threads to finish the same tick? When are the migrating entities merged into the main list, and are you using another barrier for that?

Thanks for the explanation! I happened to be thinking of similar multithreading ideas (chunks and ping-ponging states) recently, but was stuck on what happens when computation happens across chunks in multiple threads. e.g. an object move across chunk border, or an object interaction affecting two objects in different chunks. Could you elavorate on your approach about these? I'm really curious