diff --git a/dmd/mars.h b/dmd/mars.h index af664dfb..685b6f6e 100644 --- a/dmd/mars.h +++ b/dmd/mars.h @@ -301,7 +301,6 @@ struct Param OUTPUTFLAG output_bc; OUTPUTFLAG output_s; OUTPUTFLAG output_o; - bool llvmAnnotate; bool useInlineAsm; bool verbose_cg; bool useAvailableExternally; diff --git a/dmd2/mars.h b/dmd2/mars.h index 15db45be..a158e192 100644 --- a/dmd2/mars.h +++ b/dmd2/mars.h @@ -298,7 +298,6 @@ struct Param OUTPUTFLAG output_bc; OUTPUTFLAG output_s; OUTPUTFLAG output_o; - bool llvmAnnotate; bool useInlineAsm; bool verbose_cg; bool useAvailableExternally; diff --git a/driver/cl_options.cpp b/driver/cl_options.cpp index cc44b994..537eba64 100644 --- a/driver/cl_options.cpp +++ b/driver/cl_options.cpp @@ -102,11 +102,6 @@ static cl::opt debugInfo( cl::location(global.params.symdebug), cl::init(0)); - -static cl::opt annotate("annotate", - cl::desc("Annotate the bitcode with human readable source code"), - cl::location(global.params.llvmAnnotate)); - cl::opt noAsm("noasm", cl::desc("Disallow use of inline assembler")); diff --git a/gen/llvmhelpers.cpp b/gen/llvmhelpers.cpp index 0852496a..16cc4ce7 100644 --- a/gen/llvmhelpers.cpp +++ b/gen/llvmhelpers.cpp @@ -1548,24 +1548,6 @@ LLConstant* DtoConstExpInit(Loc loc, Type* type, Expression* exp) ////////////////////////////////////////////////////////////////////////////////////////// -void DtoAnnotation(const char* str) -{ - std::string s("CODE: "); - s.append(str); - char* p = &s[0]; - while (*p) - { - if (*p == '"') - *p = '\''; - ++p; - } - // create a noop with the code as the result name! - // FIXME: this is const folded and eliminated immediately ... :/ - gIR->ir->CreateAnd(DtoConstSize_t(0),DtoConstSize_t(0),s.c_str()); -} - -////////////////////////////////////////////////////////////////////////////////////////// - LLConstant* DtoTypeInfoOf(Type* type, bool base) { type = type->merge2(); // needed.. getTypeInfo does the same diff --git a/gen/llvmhelpers.h b/gen/llvmhelpers.h index a191adca..4f3a688c 100644 --- a/gen/llvmhelpers.h +++ b/gen/llvmhelpers.h @@ -123,9 +123,6 @@ LLConstant* DtoConstInitializer(Loc loc, Type* type, Initializer* init); LLConstant* DtoConstExpInit(Loc loc, Type* t, Expression* exp); DValue* DtoInitializer(LLValue* target, Initializer* init); -// annotation generator -void DtoAnnotation(const char* str); - // getting typeinfo of type, base=true casts to object.TypeInfo LLConstant* DtoTypeInfoOf(Type* ty, bool base=true); diff --git a/gen/statements.cpp b/gen/statements.cpp index 00f5fb62..39fb2b5c 100644 --- a/gen/statements.cpp +++ b/gen/statements.cpp @@ -194,8 +194,6 @@ void ExpStatement::toIR(IRState* p) DtoDwarfStopPoint(loc.linnum); if (exp) { - if (global.params.llvmAnnotate) - DtoAnnotation(exp->toChars()); elem* e; // a cast(void) around the expression is allowed, but doesn't require any code if(exp->op == TOKcast && exp->type == Type::tvoid) { diff --git a/gen/tocall.cpp b/gen/tocall.cpp index bf3dc9ed..7d8c72b7 100644 --- a/gen/tocall.cpp +++ b/gen/tocall.cpp @@ -260,8 +260,6 @@ void DtoBuildDVarArgList(std::vector& args, for (int i=begin,k=0; i(arguments->data[i]); - if (global.params.llvmAnnotate) - DtoAnnotation(argexp->toChars()); LLValue* argdst = DtoGEPi(mem,0,k); argdst = DtoBitCast(argdst, getPtrToType(DtoType(argexp->type))); DtoVariadicArgument(argexp, argdst);