DhruvSrivastavaX wrote:

> A couple of quick notes:
> 
> * are you sure that ObjectFileELF is the best thing to start with here? Based 
> on the name, I would expect that ObjectFilePECOFF would be a better baseline. 
> Or maybe the object file format is different enough from all of the existing 
> ones that this kind of comparison is not useful?
> * without also seeing the cpp file, it hard to judge how similar it is to the 
> other plugin
> * instead of redeclaring all the header types, would it be possible to use 
> some structures from llvm? (I know that ObjectFileELF does not do that, but 
> that's because it is very old. ObjectFilePECOFF -- a much newer class -- does 
> just that)
> * a lot of the object file code should be testable on its own. If you include 
> the necessary plugin glue in this PR, then you should be able to write tests 
> similar to those in `lldb/test/Shell/ObjectFile`. For example, if you could 
> start with a test similar to `test/Shell/ObjectFile/ELF/basic-info.yaml` and 
> then include enough of code in the PR to make that pass.

Hi @labath , 

1. Actually there might be slight similarities with ObjectFilePECOFF, but the 
overall format structure is very different to be compared to any one of the 
existing formats, so I have just taken the ObjectFileELF.h as a base to follow 
the general class/file arrangement. 
2. As per our last discussion, I have planned to drop each of the major files 
separately, so I can push the .cpp file as another commit, and both of these 
can be used for comparison. 
3. From a surface level I can see that ObjectFilePECOFF has also created its 
own new structures based on its file format, essentially we have done something 
similar for XCOFF. Although, let me check the existing llvm structures for 
XCOFF thoroughly and get back to you on this. 
4. So, as per your suggestion, what path flow should we take? 
Based on previous discussions, as of now I am planning a commit for .h file, 
another commit for .cpp file and a final commit for the test cases. Is that 
okay?

https://github.com/llvm/llvm-project/pull/111814
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to