[llvm] [NVPTX] Support for fence.acquire and fence.release (PR #124865)
Artem Belevich via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 29 12:48:08 PST 2025
================
@@ -0,0 +1,165 @@
+; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 5
+
+; RUN: llc < %s -march=nvptx64 -mcpu=sm_30 -mattr=+ptx50 | FileCheck %s --check-prefix=SM30
+; RUN: %if ptxas %{ llc < %s -march=nvptx -mcpu=sm_30 -mattr=+ptx50 | %ptxas-verfy %}
+
+
+define void @fence_acquire_() {
+; SM30-LABEL: fence_acquire_(
+; SM30: {
+; SM30-EMPTY:
+; SM30-EMPTY:
+; SM30-NEXT: // %bb.0:
+; SM30-NEXT: membar.sys;
+; SM30-NEXT: ret;
+ fence syncscope("") acquire
+ ret void
+}
----------------
Artem-B wrote:
Per-GPU tests appear to be nearly identical. It would be useful to restructure the tests so that the operations supported on all GPUs are tested in the same file. It makes it easier to see which instructions we generate for particular variant, all in one place.
It looks like currently we have two classes -- "cluster"-scoped operations, and everything else, so we'll have just two tests.
https://github.com/llvm/llvm-project/pull/124865
More information about the llvm-commits
mailing list