Changing The '.' Used to Prefix Labels in Assembly Output

I’m working on an LLVM back end with output to assembly file (.s). I’m using the ARM assembly printer.
The generated labels (e.g. for a while statement) start with ‘.’ like .LBB0_1
I would like to change the ‘.’ to something else (specifically $$ if it matters).
I see a lot of customizability in targetinfo.cpp but not that particular item.

Where should I be looking?

The generated labels (e.g. for a while statement) start with '.' like
.LBB0_1
I would like to change the '.' to something else (specifically $$ if it
matters).
I see a lot of customizability in targetinfo.cpp but not that particular
item.

I think you probably want the MCAsmInfo members (PrivateLabelPrefix,
for example).

Cheers.

Tim.

I'm working on an LLVM back end with output to assembly file (.s). I'm using
the ARM assembly printer.
The generated labels (e.g. for a while statement) start with '.' like
.LBB0_1
I would like to change the '.' to something else (specifically $$ if it
matters).
I see a lot of customizability in targetinfo.cpp but not that particular
item.

Where should I be looking?

I believe MCAsmInfo is what you're looking for. (for ARM, in
lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.cpp)

-Ahmed

(+llvmdev)

Thanks. Thats sounds exactly the right thing.

I couldn't actually find any instance of PrivateLabelPrefix though.

It might not be used directly by ARMMCAsmInfo.cpp, as there's a class
hierarchy mirroring the object file formats/platforms/target
relationships (doxygen is helpful for this kind of thing:
http://llvm.org/doxygen/)

See the MCAsmInfo class declaration for the base class:
include/llvm/MC/MCAsmInfo.h

-Ahmed