Windows 和 Linux 的IPC API對應表
【原文:http://blog.csdn.net/zhengdy/article/details/5485472】
Windows 和 Linux 的IPC API對應表
Windows | Linux | Classification |
---|---|---|
CreateProcess() CreateProcessAsUser() |
fork() setuid() exec() |
Mappable |
TerminateProcess() | kill() | Mappable |
SetThreadpriority() GetThreadPriority() |
Setpriority() GetPriority() |
Mappable |
GetCurrentProcessID() | getpid() | Mappable |
Exitprocess() | exit() | Mappable |
WaitForSingleObjec() WaitForMultipleObject() GetExitCodeProcess() |
waitpid() ※Using Sys V semaphores, WaitForSingleObjec/MultipleObject can be implemented |
Context specific |
GetEnvironmentVariable() SetEnvironmentVariable() |
getenv() setenv() |
Mappable |
Windows | Linux | Classification |
---|---|---|
CreateThread() | pthread_create pthread_attr_init pthread_attr_setstacksize pthread_attr_destroy |
Mappable |
ThreadExit() | pthread_exit | Mappable |
WaitForSingleObject() | pthread_join pthread_attr_setdetachstate pthread_detach |
Mappable |
SetPriorityClass() SetThreadPriority() |
setpriority sched_setscheduler sched_setparam pthread_setschedparam pthread_setschedpolicy pthread_attr_setschedparam pthread_attr_setschedpolicy> |
Context Specific |
Windows | Linux -- threads | Linux -- process |
---|---|---|
Mutex | Mutex - pthread library | System V semaphores |
Critical section | Mutex - pthread library | Not applicable as critical sections are used only between the threads of the same process |
Semaphore | Conditional Variable with mutex - pthreads POSIX semaphores |
System V Semaphores |
Event | Conditional Variable with mutex - pthreads | System V Semaphores |
Windows | Linux -- threads | Linux -- process | Classification |
---|---|---|---|
CreateSemaphore | sem_init | semget semctl |
Context specific |
OpenSemaphore | Not applicable | semget | Context specific |
WaitForSingleObject | sem_wait sem_trywait |
semop | Context specific |
ReleaseSemaphore | sem_post | semop | Context specific |
CloseHandle | sem_destroy | semctl | Context specific |
Windows | Linux -- threads | Linux -- process | Classification |
---|---|---|---|
CreateEvent OpenEvent |
pthread_cond_init sem_init |
semget semctl |
Context specific |
SetEvent | pthread_cond_signal sem_post |
semop | Context specific |
ResetEvent | N/A | N/A | Context specific |
WaitForSingleObject | pthread_cond_wait pthread_cond_timedwait sem_wait sem_trywait |
semop | Context specific |
CloseHandle | pthread_cond_destroy sem_destroy |
semctl | Context specific |
Windows | Linux -- threads | Linux -- process | Classification |
---|---|---|---|
CreateMutex | pthreads_mutex_init | semget semctl |
Context specific |
OpenMutex | Not applicable | semget | Context specific |
WaitForSingleObject | pthread_mutex_lock pthread_mutex_trylock |
semop | Context specific |
ReleaseMutex | pthread_mutex_unlock | semop | Context specific |
CloseHandle | pthread_mutex_destroy | semctl | Context specific |
Windows | Linux | Classification |
---|---|---|
InitializeCriticalSection InitializeCriticalSectionAndSpinCount |
pthreads_mutex_init | Mappable |
EnterCriticalSection TryEnterCriticalSection |
pthread_mutex_lock pthread_mutex_trylock |
Mappable |
LeaveCriticalSection | pthread_mutex_unlock | Mappable |
DeleteCriticalSection | pthread_mutex_destroy | Mappable |
Windows | Linux -- threads | Linux -- process | Classification |
---|---|---|---|
SignalObjectAndWait | semop | semop | Context specific |
WaitForMultipleObjects | sem_wait sem_trywait |
semop | Context specific |
相關文章
- APISIX Ingress 對 Gateway API 的支援和應用APIGateway
- linux ipc namespace筆記Linuxnamespace筆記
- Windows和Linux系統對比,哪個先進?WindowsLinux
- windows域控裡,屬性和欄位對映表Windows
- Linux系統和Windows系統對比?哪個更好?LinuxWindows
- Linux和Windows系統對比,哪個更加先進?LinuxWindows
- linux使用者api和核心apiLinuxAPI
- 在 mysql 下 建立新的資料庫和對應的表MySql資料庫
- linux程式間通訊(IPC)小結Linux
- [轉帖]CentOS 各版本的對應核心表和發行時間表【全】CentOS
- Linux 常見的六大 IPC 通訊方式Linux
- linux和windows系統的區別LinuxWindows
- 對比Restful Api和RpcRESTAPIRPC
- 針對Linux和Windows使用者的新型多平臺惡意軟體LinuxWindows
- ThreadX——IPC應用之訊息佇列thread佇列
- MariaDB在Linux和Windows上的安裝LinuxWindows
- Linux記憶體效能指標和工具的對應關係圖Linux記憶體指標
- django | 根據 model 建立對應的表Django
- Linux 或 Windows 上實現埠對映LinuxWindows
- MyBatis Java 和 資料庫 資料型別對應表MyBatisJava資料庫資料型別
- Laravel從已有資料庫表生成對應的migration和seed檔案Laravel資料庫
- UEFI雙啟動Windows和LinuxWindowsLinux
- 比較Windows和Linux SQL容器WindowsLinuxSQL
- Linux、Mac和Windows安裝GradleLinuxMacWindowsGradle
- Windows 和 Linux 上安裝 TTF 字型的方法WindowsLinux
- Linux和windows系統之間的區別LinuxWindows
- Linux和Windows的差異?0基礎需知!LinuxWindows
- Linux和Windows有啥區別?Linux基礎LinuxWindows
- Linux 中的負載高低和 CPU 開銷並不完全對應Linux負載
- React hooks 對應 ClassComponent 中的生命週期與 apiReactHookAPI
- Linux與windows對比有什麼優勢?對比分析!LinuxWindows
- Android sdk版本號和API級別的對照表AndroidAPI
- 對api請求封裝的探索和總結API封裝
- HBase 的結構與表的對應關係
- PostgreSQL的表檔案以及TOAST表檔案對應關係SQLAST
- 瞭解用於 Linux 和 Windows 容器的 Docker “容器LinuxWindowsDocker
- IPC call
- TCP對應的協議和UDP對應的協議(簡單概述)TCP協議UDP
- Windows和Linux伺服器禁用pingWindowsLinux伺服器