[Lldb-commits] [PATCH] D96766: [lldb] [Process/FreeBSD] Introduce mips64 FPU reg support

Jessica Clarke via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Mon Feb 22 16:15:34 PST 2021

jrtc27 added inline comments.

Comment at: lldb/source/Plugins/Process/Utility/RegisterContextFreeBSD_mips64.cpp:141
+  uint64_t f31;
+  uint64_t fcsr;
+  uint64_t fir;
MIPS calls it FCSR, FreeBSD's regnum.h calls it FSR. I don't know which is the right thing to use, but just thought I should point it out if you hadn't noticed.

Comment at: lldb/source/Plugins/Process/Utility/RegisterContextFreeBSD_mips64.cpp:161-167
+  // Check if RegisterSet is available
+  if (set < k_num_register_sets)
+    return &g_reg_sets_mips64[set];
+  return nullptr;
+size_t RegisterContextFreeBSD_mips64::GetRegisterSetCount() const {
These diffs should be separated from this commit IMO.

Comment at: lldb/source/Plugins/Process/Utility/RegisterInfos_mips64.h:26
 // Computes the offset of the given FPR in the extended data area.
+#ifdef LINUX_MIPS64
 #define FPR_OFFSET(regname)                                                    \
Should these not live in the respective RegisterContext<OS>_mips64.cpp?

Comment at: lldb/source/Plugins/Process/Utility/RegisterInfos_mips64.h:37
 // Computes the offset of the given MSA in the extended data area.
 #define MSA_OFFSET(regname)                                                    \
   (LLVM_EXTENSION offsetof(UserArea, msa) +                                    \
This and DEFINE_GPR_INFO should not be defined like this on FreeBSD (or at all?).



More information about the lldb-commits mailing list