首页 \ 问答 \ 多个设备之间的原子操作(Atomic operations between multiple devices)

多个设备之间的原子操作(Atomic operations between multiple devices)

我正在使用OpenCL在具有CPU和GPU(实际上是AMD APU)的异构系统中开发一些东西。 由于我将使用原子操作来保证数据的完整性,并且数据在CPU设备和GPU设备之间共享,在每个上都有共享数据上运行的内核。 我的问题是:原子操作在这两个设备之间仍然有效吗? 希望有人能帮助我。 非常感谢。


I am developing something in heterogeneous systems with CPU and GPU (AMD APU, in fact) with OpenCL. Since I will use atomic operations to guarantee the integrity of data, and the data is shared among CPU device and GPU device, on each of which there is a kernel running on the shared data. My question is: is atomic operation still valid between these two devices? Hope anyone can help me. Many thanks.


原文:https://stackoverflow.com/questions/12583320
更新时间:2023-08-07 13:08

最满意答案

我使用'ANT'选项..

在build.xml

<project name="myName" default="all" basedir=".">
  <taskdef name="schematron"
          classname="com.schematron.ant.SchematronTask"
          classpath="lib/ant-schematron-2010-04-14.jar;lib/saxon9he.jar"/>

  <target name="all" description="test it">
    <schematron schema="sch/test.sch" failonerror="false" debugMode="true">
      <fileset dir="./xml" includes="*.xml"/>
    </schematron>
  </target>

</project>

debugMode = true显示中间XSLT文件


I use the 'ANT' option..

Build.xml

<project name="myName" default="all" basedir=".">
  <taskdef name="schematron"
          classname="com.schematron.ant.SchematronTask"
          classpath="lib/ant-schematron-2010-04-14.jar;lib/saxon9he.jar"/>

  <target name="all" description="test it">
    <schematron schema="sch/test.sch" failonerror="false" debugMode="true">
      <fileset dir="./xml" includes="*.xml"/>
    </schematron>
  </target>

</project>

debugMode=true shows you the intermediate XSLT file

相关问答

更多