[llvm-commits] CVS: llvm-gcc/gcc/llvm-expand.c llvm-representation.c
Chris Lattner
lattner at cs.uiuc.edu
Sat Nov 27 12:33:01 PST 2004
Changes in directory llvm-gcc/gcc:
llvm-expand.c updated: 1.62 -> 1.63
llvm-representation.c updated: 1.11 -> 1.12
---
Log message:
Adjust horrible code to match what GCC is doing now. This fixes PR459: http://llvm.cs.uiuc.edu/PR459 and
test/Regression/C++Frontend/2004-11-27-EmitsUnusedInlineFunctions.cpp.
---
Diffs of the changes: (+4 -7)
Index: llvm-gcc/gcc/llvm-expand.c
diff -u llvm-gcc/gcc/llvm-expand.c:1.62 llvm-gcc/gcc/llvm-expand.c:1.63
--- llvm-gcc/gcc/llvm-expand.c:1.62 Sat Nov 27 13:45:12 2004
+++ llvm-gcc/gcc/llvm-expand.c Sat Nov 27 14:32:49 2004
@@ -7090,12 +7090,6 @@
if (!DECL_LLVM_SET_P(decl))
llvm_make_decl_llvm(decl, asmspec);
-
- if (DECL_LLVM_SET_P(decl)) { /* Ignore builtin functions */
- /* This horrible code mirrors code found in varasm.c:assemble_name */
- if (!llvm_value_is_global(DECL_LLVM(decl))) abort();
- MarkNameAsUsed(DECL_LLVM(decl)->Name);
- }
}
Index: llvm-gcc/gcc/llvm-representation.c
diff -u llvm-gcc/gcc/llvm-representation.c:1.11 llvm-gcc/gcc/llvm-representation.c:1.12
--- llvm-gcc/gcc/llvm-representation.c:1.11 Sun Oct 17 23:15:45 2004
+++ llvm-gcc/gcc/llvm-representation.c Sat Nov 27 14:32:49 2004
@@ -249,13 +249,16 @@
fprintf(F, " to ");
llvm_type_print(G2V(GV)->Ty, F);
fprintf(F, ")");
-
} else if (V->Name[0]) {
fprintf(F, "%%%s", V->Name);
} else if (!PrintType) {
fprintf(stderr, "ERROR, didn't print ANYTHING for operand!");
abort();
}
+
+ /* This horrible code mirrors code found in varasm.c:assemble_name */
+ if (llvm_value_is_global(V))
+ MarkNameAsUsed(V->Name);
}
/* llvm_constant implementation ********************************************
More information about the llvm-commits
mailing list