[llvm] [SandboxIR] Added setVolatile member function to LoadInst and StoreInst (PR #101284)

Julius Alexandre via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 31 14:00:36 PDT 2024


================
@@ -160,26 +160,28 @@ void CallBrInstSetIndirectDest::dump() const {
 }
 #endif
 
-SetVolatile::SetVolatile(Instruction *I, bool WasBool, Tracker &Tracker)
-    : IRChangeBase(Tracker), Inst(I) {
-  if (auto *Load = cast<llvm::LoadInst>(Inst)) {
+SetVolatile::SetVolatile(Instruction *I, Tracker &Tracker)
+    : IRChangeBase(Tracker) {
+  if (auto *Load = cast<llvm::LoadInst>(I)) {
----------------
medievalghoul wrote:

there's no viable overloaded '='. So when i remove  `llvm::` from `llvm::LoadInst`, making `InstUnion = Load` incorrect. So I end up getting compiler errors. Should I implement the operator overloads for StoreInst and LoadInst or is there another solution?

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


More information about the llvm-commits mailing list