Skip to content

Commit

Permalink
[#2] Rename concurrency primitives into concurrency sync
Browse files Browse the repository at this point in the history
  • Loading branch information
elfenpiff committed Dec 13, 2023
1 parent f0ef902 commit d019d86
Show file tree
Hide file tree
Showing 27 changed files with 33 additions and 33 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ jobs:
# - name: Run cargo test subset
# run: |
# cargo test
# -p iceoryx2_pal_concurrency_primitives
# -p iceoryx2_pal_concurrency_sync
# -p iceoryx2_pal_posix
# -p iceoryx2_bb_container
# -p iceoryx2_bb_elementary
Expand Down
4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ members = [

"iceoryx2-cal",
"iceoryx2",
"iceoryx2-pal/concurrency-primitives",
"iceoryx2-pal/concurrency-sync",
"iceoryx2-pal/posix/",
"iceoryx2-pal/configuration/",

Expand Down Expand Up @@ -45,7 +45,7 @@ iceoryx2-bb-posix = { version = "0.0.1", path = "iceoryx2-bb/posix/" }
iceoryx2-bb-system-types = { version = "0.0.1", path = "iceoryx2-bb/system-types/" }
iceoryx2-bb-testing = { version = "0.0.1", path = "iceoryx2-bb/testing/" }

iceoryx2-pal-concurrency-primitives = { version = "0.0.1", path = "iceoryx2-pal/concurrency-primitives/" }
iceoryx2-pal-concurrency-sync = { version = "0.0.1", path = "iceoryx2-pal/concurrency-sync/" }
iceoryx2-pal-posix = { version = "0.0.1", path = "iceoryx2-pal/posix/" }
iceoryx2-pal-configuration = { version = "0.0.1", path = "iceoryx2-pal/configuration/" }

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "iceoryx2-pal-concurrency-primitives"
name = "iceoryx2-pal-concurrency-sync"
description = "Iceoryx2: [internal] low-level basic building blocks to implement posix mutex, condition variables etc."
categories = { workspace = true }
edition = { workspace = true }
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
use std::sync::atomic::{AtomicI32, Ordering};

use iceoryx2_bb_testing::assert_that;
use iceoryx2_pal_concurrency_primitives::barrier::*;
use iceoryx2_pal_concurrency_sync::barrier::*;

#[test]
fn barrier_with_multiple_waiter_works() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ use std::{
};

use iceoryx2_bb_testing::{assert_that, watchdog::Watchdog};
use iceoryx2_pal_concurrency_primitives::{barrier::Barrier, condition_variable::*};
use iceoryx2_pal_concurrency_sync::{barrier::Barrier, condition_variable::*};

const TIMEOUT: Duration = Duration::from_millis(25);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ use std::{
};

use iceoryx2_bb_testing::assert_that;
use iceoryx2_pal_concurrency_primitives::mutex::*;
use iceoryx2_pal_concurrency_sync::mutex::*;

const TIMEOUT: Duration = Duration::from_millis(25);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ use std::{
};

use iceoryx2_bb_testing::assert_that;
use iceoryx2_pal_concurrency_primitives::{barrier::Barrier, rwlock::*};
use iceoryx2_pal_concurrency_sync::{barrier::Barrier, rwlock::*};

const TIMEOUT: Duration = Duration::from_millis(25);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ use std::{
};

use iceoryx2_bb_testing::assert_that;
use iceoryx2_pal_concurrency_primitives::semaphore::*;
use iceoryx2_pal_concurrency_sync::semaphore::*;

const TIMEOUT: Duration = Duration::from_millis(25);

Expand Down
2 changes: 1 addition & 1 deletion iceoryx2-pal/posix/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ cc = { workspace = true }
bindgen = { workspace = true }

[dependencies]
iceoryx2-pal-concurrency-primitives = { workspace = true }
iceoryx2-pal-concurrency-sync = { workspace = true }
iceoryx2-pal-configuration = { workspace = true }
lazy_static = { workspace = true }

Expand Down
2 changes: 1 addition & 1 deletion iceoryx2-pal/posix/src/macos/mman.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
#![allow(non_camel_case_types)]
#![allow(clippy::missing_safety_doc)]

use iceoryx2_pal_settings::PATH_SEPARATOR;
use iceoryx2_pal_configuration::PATH_SEPARATOR;

use crate::posix::*;

Expand Down
6 changes: 3 additions & 3 deletions iceoryx2-pal/posix/src/macos/pthread.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
use crate::posix::*;

use core::sync::atomic::{AtomicU32, Ordering};
use iceoryx2_pal_concurrency_primitives::barrier::Barrier;
use iceoryx2_pal_concurrency_primitives::mutex::Mutex;
use iceoryx2_pal_concurrency_primitives::rwlock::*;
use iceoryx2_pal_concurrency_sync::barrier::Barrier;
use iceoryx2_pal_concurrency_sync::mutex::Mutex;
use iceoryx2_pal_concurrency_sync::rwlock::*;
use std::cell::UnsafeCell;

#[derive(Clone, Copy)]
Expand Down
2 changes: 1 addition & 1 deletion iceoryx2-pal/posix/src/macos/semaphore.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
#![allow(clippy::missing_safety_doc)]
#![allow(unused_variables)]

use iceoryx2_pal_concurrency_primitives::semaphore::Semaphore;
use iceoryx2_pal_concurrency_sync::semaphore::Semaphore;

use crate::posix::pthread::{wait, wake_one};
use crate::posix::Errno;
Expand Down
2 changes: 1 addition & 1 deletion iceoryx2-pal/posix/src/macos/settings.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@

pub(crate) const MAX_FILE_NAME_LENGTH: usize = 255;
pub(crate) const MAX_PATH_LENGTH: usize = 255;
pub(crate) const SHM_STATE_DIRECTORY: &[u8] = iceoryx2_pal_settings::TEMP_DIRECTORY;
pub(crate) const SHM_STATE_DIRECTORY: &[u8] = iceoryx2_pal_configuration::TEMP_DIRECTORY;
pub(crate) const SHM_STATE_SUFFIX: &[u8] = b".shm_state";
10 changes: 5 additions & 5 deletions iceoryx2-pal/posix/src/macos/types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@

use crate::posix::{Struct, *};
use core::sync::atomic::AtomicU64;
use iceoryx2_pal_concurrency_primitives::barrier::Barrier;
use iceoryx2_pal_concurrency_primitives::condition_variable::*;
use iceoryx2_pal_concurrency_primitives::mutex::Mutex;
use iceoryx2_pal_concurrency_primitives::rwlock::*;
use iceoryx2_pal_concurrency_primitives::semaphore::*;
use iceoryx2_pal_concurrency_sync::barrier::Barrier;
use iceoryx2_pal_concurrency_sync::condition_variable::*;
use iceoryx2_pal_concurrency_sync::mutex::Mutex;
use iceoryx2_pal_concurrency_sync::rwlock::*;
use iceoryx2_pal_concurrency_sync::semaphore::*;

pub type ulong = usize;

Expand Down
2 changes: 1 addition & 1 deletion iceoryx2-pal/posix/src/windows/mman.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
use crate::posix::{constants::*, settings::*, to_dir_search_string, types::*, Errno, Struct};
use crate::win32call;

use iceoryx2_pal_settings::PATH_SEPARATOR;
use iceoryx2_pal_configuration::PATH_SEPARATOR;
use windows_sys::Win32::Storage::FileSystem::{
FindClose, FindFirstFileA, FindNextFileA, FILE_ATTRIBUTE_DIRECTORY, WIN32_FIND_DATAA,
};
Expand Down
4 changes: 2 additions & 2 deletions iceoryx2-pal/posix/src/windows/pthread.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ use std::{
time::UNIX_EPOCH,
};

use iceoryx2_pal_concurrency_primitives::rwlock::*;
use iceoryx2_pal_concurrency_primitives::{barrier::Barrier, mutex::Mutex};
use iceoryx2_pal_concurrency_sync::rwlock::*;
use iceoryx2_pal_concurrency_sync::{barrier::Barrier, mutex::Mutex};
use windows_sys::Win32::{
Foundation::{CloseHandle, ERROR_TIMEOUT, STILL_ACTIVE, WAIT_FAILED},
System::{
Expand Down
2 changes: 1 addition & 1 deletion iceoryx2-pal/posix/src/windows/semaphore.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ use std::sync::atomic::AtomicU32;
use std::time::SystemTime;
use std::time::UNIX_EPOCH;

use iceoryx2_pal_concurrency_primitives::semaphore::Semaphore;
use iceoryx2_pal_concurrency_sync::semaphore::Semaphore;
use windows_sys::Win32::System::Threading::WaitOnAddress;
use windows_sys::Win32::System::Threading::WakeByAddressSingle;
use windows_sys::Win32::System::Threading::INFINITE;
Expand Down
2 changes: 1 addition & 1 deletion iceoryx2-pal/posix/src/windows/settings.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
use windows_sys::Win32::Foundation::MAX_PATH;

pub(crate) const MAX_PATH_LENGTH: usize = MAX_PATH as usize;
pub(crate) const SHM_STATE_DIRECTORY: &[u8] = iceoryx2_pal_settings::TEMP_DIRECTORY;
pub(crate) const SHM_STATE_DIRECTORY: &[u8] = iceoryx2_pal_configuration::TEMP_DIRECTORY;
pub(crate) const SHM_STATE_SUFFIX: &[u8] = b".shm_state";
#[doc(hidden)]
pub const FD_SET_CAPACITY: usize = 64;
2 changes: 1 addition & 1 deletion iceoryx2-pal/posix/src/windows/signal.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
#![allow(clippy::missing_safety_doc)]
#![allow(unused_variables)]

use iceoryx2_pal_concurrency_primitives::mutex::Mutex;
use iceoryx2_pal_concurrency_sync::mutex::Mutex;
use windows_sys::Win32::{
Foundation::{FALSE, TRUE},
System::{
Expand Down
10 changes: 5 additions & 5 deletions iceoryx2-pal/posix/src/windows/types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@
use std::fmt::Debug;
use std::sync::atomic::AtomicU64;

use iceoryx2_pal_concurrency_primitives::barrier::Barrier;
use iceoryx2_pal_concurrency_primitives::condition_variable::*;
use iceoryx2_pal_concurrency_primitives::mutex::Mutex;
use iceoryx2_pal_concurrency_primitives::rwlock::*;
use iceoryx2_pal_concurrency_primitives::semaphore::Semaphore;
use iceoryx2_pal_concurrency_sync::barrier::Barrier;
use iceoryx2_pal_concurrency_sync::condition_variable::*;
use iceoryx2_pal_concurrency_sync::mutex::Mutex;
use iceoryx2_pal_concurrency_sync::rwlock::*;
use iceoryx2_pal_concurrency_sync::semaphore::Semaphore;
use windows_sys::Win32::Foundation::{HANDLE, INVALID_HANDLE_VALUE};
use windows_sys::Win32::Networking::WinSock::{SOCKADDR_IN, TIMEVAL};

Expand Down
2 changes: 1 addition & 1 deletion iceoryx2-pal/posix/src/windows/win32_handle_translator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ use windows_sys::Win32::{

use crate::posix::{c_string_length, ntohs, types::*};
use core::{cell::UnsafeCell, panic};
use iceoryx2_pal_concurrency_primitives::mutex::Mutex;
use iceoryx2_pal_concurrency_sync::mutex::Mutex;
use std::sync::atomic::{AtomicBool, AtomicU32, AtomicUsize, Ordering};

use super::win32_udp_port_to_uds_name::{PortToUds, MAX_UDS_NAME_LEN};
Expand Down

0 comments on commit d019d86

Please sign in to comment.