LLVM Back-End structur related question.

Hi everyone,

How would you pass a string container from TargetISelLowering phase to the
TargetInstPrinter phase?

May be I have missed something essential, but currently seems they don't
have shared class or something like that, and currently I am thinkin to
initialize container in TargetTargetMachine, then pass it to the
TargetInstPrinter using TargetMCAsmInfo class or something like this. I do
not like this approach.

I believe that there should be some clever solution than I am thinking.

Thanks,
Arsen

Just adding a second text for getting some attention.
I would appreciate any help here, any ideas, suggestions, even you are not
so sure.

Thanks,
Arsen

I had same issue.
This is what worked for me.

For target Specific entry
Create String Field in your target(subtarget) extension.
For instruction specific details
You can pass same with MCInst.

i asked for help on IRC. :smiley:

Thank you maheshattarde

Actually I have passed the container through TargetMCAsmInfo object. It is
available both in TargetLowering and InstPrinter phases.

The only thing which is not so good here that I have to use some tricky code
to have opportunity to modify the member data because I have only constant
object of that class.

If I will find another solution I will post it here.

Thanks,
Arsen