From 78d44be1dfb2c8761d7aaef09ca19764573157e4 Mon Sep 17 00:00:00 2001 From: yellowhatter Date: Wed, 29 May 2024 23:10:53 +0300 Subject: [PATCH] Rollback to default "shared-memory" in internals --- Cargo.toml | 6 +++--- Cargo.toml.in | 6 +++--- build-resources/opaque-types/Cargo.toml | 4 ++-- include/zenoh_commons.h | 20 ++++++++++---------- include/zenoh_concrete.h | 2 +- 5 files changed, 19 insertions(+), 19 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 6074f4552..5b8393b06 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -54,10 +54,10 @@ spin = "0.9.5" unwrap-infallible = "0.1.5" const_format = "0.2.32" # shared-memory enabled for zenoh even if zenoh-c "shared-memory" feature is disabled. This is to make "std::mem::transmute" work for `ZSLice` -zenoh = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["unstable"], default-features = false } -zenoh-protocol = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api" } +zenoh = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["unstable", "shared-memory"], default-features = false } +zenoh-protocol = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["shared-memory"] } zenoh-util = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api" } -zenoh-ext = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["unstable"] } +zenoh-ext = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["unstable", "shared-memory"] } [build-dependencies] diff --git a/Cargo.toml.in b/Cargo.toml.in index 477ef7ef9..2d8f4078b 100644 --- a/Cargo.toml.in +++ b/Cargo.toml.in @@ -54,10 +54,10 @@ spin = "0.9.5" unwrap-infallible = "0.1.5" const_format = "0.2.32" # shared-memory enabled for zenoh even if zenoh-c "shared-memory" feature is disabled. This is to make "std::mem::transmute" work for `ZSLice` -zenoh = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["unstable"], default-features = false } -zenoh-protocol = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api" } +zenoh = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["unstable", "shared-memory"], default-features = false } +zenoh-protocol = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["shared-memory"] } zenoh-util = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api" } -zenoh-ext = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["unstable"] } +zenoh-ext = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["unstable", "shared-memory"] } [build-dependencies] diff --git a/build-resources/opaque-types/Cargo.toml b/build-resources/opaque-types/Cargo.toml index 82587814c..0fa9d7d05 100644 --- a/build-resources/opaque-types/Cargo.toml +++ b/build-resources/opaque-types/Cargo.toml @@ -12,6 +12,6 @@ default = ["zenoh/default"] [dependencies] # shared-memory enabled for zenoh even if zenoh-c "shared-memory" feature is disabled. This is to make "std::mem::transmute" work for `ZSLice` -zenoh = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["unstable"], default-features = false } -zenoh-ext = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["unstable"] } +zenoh = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["unstable", "shared-memory"], default-features = false } +zenoh-ext = { version = "0.11.0-dev", git = "https://github.com/ZettaScaleLabs/zenoh.git", branch = "fix_shm_async_api", features = ["unstable", "shared-memory"] } const_format = "0.2.32" diff --git a/include/zenoh_commons.h b/include/zenoh_commons.h index 0eae11377..feb7d888f 100644 --- a/include/zenoh_commons.h +++ b/include/zenoh_commons.h @@ -289,7 +289,7 @@ typedef struct ALIGN(8) z_owned_bytes_t { * A loaned serialized Zenoh data. */ typedef struct ALIGN(8) z_loaned_bytes_t { - uint8_t _0[32]; + uint8_t _0[40]; } z_loaned_bytes_t; /** * A contiguous owned sequence of bytes allocated by Zenoh. @@ -420,7 +420,7 @@ typedef struct z_loaned_closure_owned_query_t { * Queries are atomically reference-counted, letting you extract them from the callback that handed them to you by cloning. */ typedef struct ALIGN(8) z_owned_query_t { - uint8_t _0[136]; + uint8_t _0[144]; } z_owned_query_t; /** * A closure is a structure that contains all the elements for stateful, memory-leak-free callbacks: @@ -483,7 +483,7 @@ typedef struct z_loaned_closure_reply_t { * A loaned reply. */ typedef struct ALIGN(8) z_loaned_reply_t { - uint8_t _0[240]; + uint8_t _0[256]; } z_loaned_reply_t; /** * A structure that contains all the elements for stateful, memory-leak-free callbacks. @@ -519,7 +519,7 @@ typedef struct z_loaned_closure_sample_t { * A loaned Zenoh sample. */ typedef struct ALIGN(8) z_loaned_sample_t { - uint8_t _0[224]; + uint8_t _0[240]; } z_loaned_sample_t; /** * A closure is a structure that contains all the elements for stateful, memory-leak-free callbacks. @@ -712,13 +712,13 @@ typedef struct z_delete_options_t { * The encoding of Zenoh data. */ typedef struct ALIGN(8) z_owned_encoding_t { - uint8_t _0[40]; + uint8_t _0[48]; } z_owned_encoding_t; /** * A loaned Zenoh encoding. */ typedef struct ALIGN(8) z_loaned_encoding_t { - uint8_t _0[40]; + uint8_t _0[48]; } z_loaned_encoding_t; /** * The replies consolidation strategy to apply on replies to a `z_get()`. @@ -926,7 +926,7 @@ typedef struct z_query_reply_err_options_t { * A loaned Zenoh value. */ typedef struct ALIGN(8) z_loaned_value_t { - uint8_t _0[72]; + uint8_t _0[88]; } z_loaned_value_t; /** * A loaned Zenoh queryable. @@ -938,7 +938,7 @@ typedef struct ALIGN(8) z_loaned_queryable_t { * An owned reply from a Queryable to a `z_get()`. */ typedef struct ALIGN(8) z_owned_reply_t { - uint8_t _0[240]; + uint8_t _0[256]; } z_owned_reply_t; /** * A closure is a structure that contains all the elements for stateful, memory-leak-free callbacks: @@ -990,7 +990,7 @@ typedef struct z_loaned_reply_channel_closure_t { * Like all owned types, it should be freed using z_drop or z_sample_drop. */ typedef struct ALIGN(8) z_owned_sample_t { - uint8_t _0[224]; + uint8_t _0[240]; } z_owned_sample_t; /** * A Zenoh timestamp . @@ -1109,7 +1109,7 @@ typedef struct z_time_t { * A Zenoh value - a compination of payload and its encoding. */ typedef struct ALIGN(8) z_owned_value_t { - uint8_t _0[72]; + uint8_t _0[88]; } z_owned_value_t; /** * A user allocated string, viewed as a key expression. diff --git a/include/zenoh_concrete.h b/include/zenoh_concrete.h index 4120ff6ec..58ceb4731 100644 --- a/include/zenoh_concrete.h +++ b/include/zenoh_concrete.h @@ -31,7 +31,7 @@ typedef struct ALIGN(8) z_owned_session_t { * A loaned Zenoh query. */ typedef struct ALIGN(8) z_loaned_query_t { - uint8_t _0[136]; + uint8_t _0[144]; } z_loaned_query_t; /** * A loaned Zenoh session.