[llvm-commits] [dragonegg] r133391 - in /dragonegg/trunk: include/dragonegg/Internals.h src/Convert.cpp
Duncan Sands
baldrick at free.fr
Sun Jun 19 05:36:11 PDT 2011
Author: baldrick
Date: Sun Jun 19 07:36:11 2011
New Revision: 133391
URL: http://llvm.org/viewvc/llvm-project?rev=133391&view=rev
Log:
Continue porting to gcc-4.6: remove remaining uses of MISALIGNED_INDIRECT_REF
(it has been subsumed by TARGET_MEM_REF). Correct the prototype for
get_pointer_alignment by removing it: the prototype is available in tree.h.
Based on a patch by 陳韋任.
Modified:
dragonegg/trunk/include/dragonegg/Internals.h
dragonegg/trunk/src/Convert.cpp
Modified: dragonegg/trunk/include/dragonegg/Internals.h
URL: http://llvm.org/viewvc/llvm-project/dragonegg/trunk/include/dragonegg/Internals.h?rev=133391&r1=133390&r2=133391&view=diff
==============================================================================
--- dragonegg/trunk/include/dragonegg/Internals.h (original)
+++ dragonegg/trunk/include/dragonegg/Internals.h Sun Jun 19 07:36:11 2011
@@ -805,7 +805,9 @@
LValue EmitLV_COMPONENT_REF(tree_node *exp);
LValue EmitLV_DECL(tree_node *exp);
LValue EmitLV_INDIRECT_REF(tree_node *exp);
+#if (GCC_MINOR < 6)
LValue EmitLV_MISALIGNED_INDIRECT_REF(tree_node *exp);
+#endif
LValue EmitLV_VIEW_CONVERT_EXPR(tree_node *exp);
LValue EmitLV_WITH_SIZE_EXPR(tree_node *exp);
LValue EmitLV_XXXXPART_EXPR(tree_node *exp, unsigned Idx);
Modified: dragonegg/trunk/src/Convert.cpp
URL: http://llvm.org/viewvc/llvm-project/dragonegg/trunk/src/Convert.cpp?rev=133391&r1=133390&r2=133391&view=diff
==============================================================================
--- dragonegg/trunk/src/Convert.cpp (original)
+++ dragonegg/trunk/src/Convert.cpp Sun Jun 19 07:36:11 2011
@@ -60,7 +60,6 @@
#include "tree-flow.h"
#include "tree-pass.h"
-extern int get_pointer_alignment (tree exp, unsigned int max_align);
extern enum machine_mode reg_raw_mode[FIRST_PSEUDO_REGISTER];
}
@@ -1306,9 +1305,11 @@
case INDIRECT_REF:
LV = EmitLV_INDIRECT_REF(exp);
break;
+#if (GCC_MINOR < 6)
case MISALIGNED_INDIRECT_REF:
LV = EmitLV_MISALIGNED_INDIRECT_REF(exp);
break;
+#endif
}
// Check that the type of the lvalue is indeed that of a pointer to the tree
@@ -4692,7 +4693,9 @@
case BUILT_IN_APPLY:
case BUILT_IN_RETURN:
case BUILT_IN_SAVEREGS:
+#if (GCC_MINOR < 6)
case BUILT_IN_ARGS_INFO:
+#endif
case BUILT_IN_NEXT_ARG:
case BUILT_IN_CLASSIFY_TYPE:
case BUILT_IN_AGGREGATE_INCOMING_ADDRESS:
@@ -5971,6 +5974,7 @@
return LV;
}
+#if (GCC_MINOR < 6)
LValue TreeToLLVM::EmitLV_MISALIGNED_INDIRECT_REF(tree exp) {
// The lvalue is just the address. The alignment is given by operand 1.
unsigned Alignment = tree_low_cst(TREE_OPERAND(exp, 1), true);
@@ -5986,6 +5990,7 @@
ConvertType(TREE_TYPE(exp))->getPointerTo());
return LV;
}
+#endif
LValue TreeToLLVM::EmitLV_VIEW_CONVERT_EXPR(tree exp) {
// The address is the address of the operand.
@@ -8497,7 +8502,9 @@
case COMPONENT_REF:
case IMAGPART_EXPR:
case INDIRECT_REF:
+#if (GCC_MINOR < 6)
case MISALIGNED_INDIRECT_REF:
+#endif
case REALPART_EXPR:
case TARGET_MEM_REF:
case VIEW_CONVERT_EXPR:
More information about the llvm-commits
mailing list