[llvm] [SandboxIR] Implemented isVolatile() for LoadInst (PR #100717)

via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 26 08:18:11 PDT 2024


================
@@ -737,7 +737,7 @@ define void @foo(i1 %cond0, i1 %cond2) {
 TEST_F(SandboxIRTest, LoadInst) {
   parseIR(C, R"IR(
 define void @foo(ptr %arg0, ptr %arg1) {
-  %ld = load i8, ptr %arg0, align 64
+  %ld = load volatile i8, ptr %arg0, align 64
----------------
vporpo wrote:

Nit: Let's keep both the original non-volatile load and the volatile load, and `EXPECT_FALSE(Ld->isVolatile())` for the first one and `EXPECT_TRUE(VolLd->isVolatile())`.

https://github.com/llvm/llvm-project/pull/100717


More information about the llvm-commits mailing list