Thanks for sending an requirement! Please fill in the following template to help quickly solve your problem.
新增IPC Event进程间同步示例,用于演示在昇腾设备上使用IPC Event实现跨进程任务同步。
Runtime
通过此示例,用户可以学习如何使用ACL的IPC Event相关接口进行进程间同步,包括aclrtCreateEventExWithFlag、aclrtIpcGetEventHandle、aclrtIpcOpenEvent、aclrtStreamWaitEvent、aclrtRecordEvent等
该示例包含两个进程:
proc_a.cpp:生产者进程,创建IPC事件,导出共享内存,等待消费者触发事件后读取共享内存并验证。
proc_b.cpp:消费者进程,导入IPC事件和共享内存,修改内存数据,记录事件通知生产者。
Thanks for sending an requirement! Please fill in the following template to help quickly solve your problem.
Backgroud(背景信息)
新增IPC Event进程间同步示例,用于演示在昇腾设备上使用IPC Event实现跨进程任务同步。
Origin(信息来源)
Runtime
Benefit / Necessity (价值/作用)
通过此示例,用户可以学习如何使用ACL的IPC Event相关接口进行进程间同步,包括aclrtCreateEventExWithFlag、aclrtIpcGetEventHandle、aclrtIpcOpenEvent、aclrtStreamWaitEvent、aclrtRecordEvent等
Design(设计方案)
该示例包含两个进程:
proc_a.cpp:生产者进程,创建IPC事件,导出共享内存,等待消费者触发事件后读取共享内存并验证。
proc_b.cpp:消费者进程,导入IPC事件和共享内存,修改内存数据,记录事件通知生产者。