jj10306 added inline comments.
================
Comment at: lldb/source/Target/TraceHTR.cpp:205-217
+ // Why does using `IHTRLayer ¤t_layer = m_instruction_layer;` not work?
+ HTRInstructionLayer instruction_layer = m_instruction_layer;
+ HTRBlockLayer current_layer = BasicSuperBlockMerge(instruction_layer);
+ if (instruction_layer.GetNumUnits() == current_layer.GetNumUnits())
+ return;
+ AddNewBlockLayer(current_layer);
+ while (true) {
----------------
Any idea why the "Edit" I made above does not work?
I tried this first but after using lldb to understand why it wasn't working, it
appeared that `current_layer = new_block_layer` wasn't properly updating the
value stored in `current_layer`. I thought that using a reference to an
abstract class as the type for `current_layer` would allow this variable to
bind to any value that implements the interface, but after changing the code to
only use concrete types (the non-edited version of this code), the code behaves
as expected.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D105741/new/
https://reviews.llvm.org/D105741
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits