mirror of
https://github.com/RPCSX/llvm.git
synced 2024-12-04 18:06:49 +00:00
We now allow targets to use any prefix they want for global symbols. Lets
hear it for ".". git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@15863 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
9e36843964
commit
af2bf0ab30
@ -44,12 +44,12 @@ namespace llvm {
|
|||||||
// Properties to be set by the derived class ctor, used to configure the
|
// Properties to be set by the derived class ctor, used to configure the
|
||||||
// asmwriter.
|
// asmwriter.
|
||||||
|
|
||||||
/// UsesUnderscorePrefix - If this flag is set to true, all identifiers
|
/// GlobalPrefix - If this is set to a non-empty string, it is prepended
|
||||||
/// printed by the asmwriter will include a '_' prefix.
|
/// onto all global symbols. This is often used for "_" or ".".
|
||||||
bool UsesUnderscorePrefix;
|
const char *GlobalPrefix;
|
||||||
|
|
||||||
AsmPrinter(std::ostream &o, TargetMachine &tm)
|
AsmPrinter(std::ostream &o, TargetMachine &tm)
|
||||||
: O(o), TM(tm), UsesUnderscorePrefix(false) { }
|
: O(o), TM(tm), GlobalPrefix("") { }
|
||||||
|
|
||||||
/// doInitialization - Set up the AsmPrinter when we are working on a new
|
/// doInitialization - Set up the AsmPrinter when we are working on a new
|
||||||
/// module. If your pass overrides this, it must make sure to explicitly
|
/// module. If your pass overrides this, it must make sure to explicitly
|
||||||
|
@ -19,7 +19,7 @@
|
|||||||
using namespace llvm;
|
using namespace llvm;
|
||||||
|
|
||||||
bool AsmPrinter::doInitialization(Module &M) {
|
bool AsmPrinter::doInitialization(Module &M) {
|
||||||
Mang = new Mangler(M, UsesUnderscorePrefix);
|
Mang = new Mangler(M, GlobalPrefix);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user