[PATCH] D136043: [CodeGen] Replace CCValAssign::Loc with a discriminated union (NFCI)
Thorsten via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Dec 17 12:41:50 PST 2022
tschuett added a comment.
I am unsure about the value of `LockKind`.
================
Comment at: llvm/include/llvm/CodeGen/CallingConvLower.h:130
+ bool isMemLoc() const { return getLocKind() == LK_Memory; }
+ bool isPendingLoc() const { return getLocKind() == LK_Pending; }
----------------
Here you could also use `std::holds_variant<unsigned>(Data)`.
================
Comment at: llvm/include/llvm/CodeGen/CallingConvLower.h:138
+
+ unsigned getExtraInfo() const { return std::get<LK_Pending>(Data); }
+
----------------
Or `std::get<int>(Data)`.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D136043/new/
https://reviews.llvm.org/D136043
More information about the llvm-commits
mailing list