[llvm-commits] [llvm-gcc-4.2] r139189 - in /llvm-gcc-4.2/trunk/gcc: config/arm/llvm-arm-target.h config/arm/llvm-arm.cpp config/i386/llvm-i386-target.h config/mips/llvm-mips-target.h config/rs6000/rs6000.h config/sparc/sparc.h llvm-abi-default.cpp llvm-abi.h llvm-convert.cpp
Bob Wilson
bob.wilson at apple.com
Tue Sep 6 14:53:06 PDT 2011
Author: bwilson
Date: Tue Sep 6 16:53:06 2011
New Revision: 139189
URL: http://llvm.org/viewvc/llvm-project?rev=139189&view=rev
Log:
Disable ARM byval. It is not supported as of r138977. <rdar://problem/10066897>
--- Reverse-merging r132251 into '.':
U gcc/config/arm/llvm-arm.cpp
--- Reverse-merging r130447 into '.':
G gcc/config/arm/llvm-arm.cpp
--- Reverse-merging r130406 into '.':
U gcc/llvm-convert.cpp
U gcc/llvm-abi-default.cpp
U gcc/llvm-abi.h
U gcc/config/sparc/sparc.h
U gcc/config/i386/llvm-i386-target.h
U gcc/config/rs6000/rs6000.h
U gcc/config/arm/llvm-arm-target.h
G gcc/config/arm/llvm-arm.cpp
U gcc/config/mips/llvm-mips-target.h
Modified:
llvm-gcc-4.2/trunk/gcc/config/arm/llvm-arm-target.h
llvm-gcc-4.2/trunk/gcc/config/arm/llvm-arm.cpp
llvm-gcc-4.2/trunk/gcc/config/i386/llvm-i386-target.h
llvm-gcc-4.2/trunk/gcc/config/mips/llvm-mips-target.h
llvm-gcc-4.2/trunk/gcc/config/rs6000/rs6000.h
llvm-gcc-4.2/trunk/gcc/config/sparc/sparc.h
llvm-gcc-4.2/trunk/gcc/llvm-abi-default.cpp
llvm-gcc-4.2/trunk/gcc/llvm-abi.h
llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
Modified: llvm-gcc-4.2/trunk/gcc/config/arm/llvm-arm-target.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/config/arm/llvm-arm-target.h?rev=139189&r1=139188&r2=139189&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/config/arm/llvm-arm-target.h (original)
+++ llvm-gcc-4.2/trunk/gcc/config/arm/llvm-arm-target.h Tue Sep 6 16:53:06 2011
@@ -98,14 +98,6 @@
#define LLVM_SHOULD_NOT_USE_SHADOW_RETURN(X, CC) \
llvm_arm_should_pass_or_return_aggregate_in_regs((X), (CC))
-extern
-bool llvm_arm_should_pass_aggregate_using_byval_attr(tree, Type *,
- CallingConv::ID &CC);
-
-#define LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(X, TY, CC) \
- (llvm_arm_should_pass_aggregate_using_byval_attr((X), (TY), (CC)))
-
-
/* Vectors bigger than 128 are returned using sret. */
#define LLVM_SHOULD_RETURN_VECTOR_AS_SHADOW(X, isBuiltin) \
(TREE_INT_CST_LOW(TYPE_SIZE(X)) > 128)
Modified: llvm-gcc-4.2/trunk/gcc/config/arm/llvm-arm.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/config/arm/llvm-arm.cpp?rev=139189&r1=139188&r2=139189&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/config/arm/llvm-arm.cpp (original)
+++ llvm-gcc-4.2/trunk/gcc/config/arm/llvm-arm.cpp Tue Sep 6 16:53:06 2011
@@ -2873,19 +2873,4 @@
return result && !TREE_ADDRESSABLE(TreeType);
}
-/* Target hook for llvm-abi.h. It returns true if an aggregate of the
- specified type should be passed with the 'byval' attribute. */
-bool llvm_arm_should_pass_aggregate_using_byval_attr(tree TreeType,
- Type *Ty,
- CallingConv::ID &CC) {
- if (CC == CallingConv::ARM_APCS ||
- (CC == CallingConv::C && !TARGET_AAPCS_BASED)) {
- enum machine_mode Mode = TYPE_MODE(TreeType);
- HOST_WIDE_INT Bytes = (Mode == BLKmode) ? int_size_in_bytes(TreeType) :
- (int) GET_MODE_SIZE(Mode);
- return Bytes > 64;
- }
- return false;
-}
-
/* LLVM LOCAL end (ENTIRE FILE!) */
Modified: llvm-gcc-4.2/trunk/gcc/config/i386/llvm-i386-target.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/config/i386/llvm-i386-target.h?rev=139189&r1=139188&r2=139189&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/config/i386/llvm-i386-target.h (original)
+++ llvm-gcc-4.2/trunk/gcc/config/i386/llvm-i386-target.h Tue Sep 6 16:53:06 2011
@@ -227,7 +227,7 @@
extern bool llvm_x86_should_pass_aggregate_in_memory(tree, Type *);
-#define LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(X, TY, CC) \
+#define LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(X, TY) \
llvm_x86_should_pass_aggregate_in_memory(X, TY)
Modified: llvm-gcc-4.2/trunk/gcc/config/mips/llvm-mips-target.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/config/mips/llvm-mips-target.h?rev=139189&r1=139188&r2=139189&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/config/mips/llvm-mips-target.h (original)
+++ llvm-gcc-4.2/trunk/gcc/config/mips/llvm-mips-target.h Tue Sep 6 16:53:06 2011
@@ -27,7 +27,7 @@
/* LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR - Return true if this aggregate
value should be passed by value, i.e. passing its address with the byval
attribute bit set. The default is false. */
-#define LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(X, TY, CC) \
+#define LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(X, TY) \
llvm_mips_should_pass_aggregate_in_memory(X, TY)
extern bool
Modified: llvm-gcc-4.2/trunk/gcc/config/rs6000/rs6000.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/config/rs6000/rs6000.h?rev=139189&r1=139188&r2=139189&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/config/rs6000/rs6000.h (original)
+++ llvm-gcc-4.2/trunk/gcc/config/rs6000/rs6000.h Tue Sep 6 16:53:06 2011
@@ -3499,7 +3499,7 @@
extern bool llvm_rs6000_should_pass_aggregate_byval(tree, Type *);
-#define LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(X, TY, CC) \
+#define LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(X, TY) \
llvm_rs6000_should_pass_aggregate_byval((X), (TY))
extern bool llvm_rs6000_should_pass_vector_in_integer_regs(tree);
Modified: llvm-gcc-4.2/trunk/gcc/config/sparc/sparc.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/config/sparc/sparc.h?rev=139189&r1=139188&r2=139189&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/config/sparc/sparc.h (original)
+++ llvm-gcc-4.2/trunk/gcc/config/sparc/sparc.h Tue Sep 6 16:53:06 2011
@@ -2488,7 +2488,7 @@
*/
#define LLVM_TARGET_NAME Sparc
-#define LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(X, TY, CC) \
+#define LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(X, TY) \
true
#endif /* ENABLE_LLVM */
Modified: llvm-gcc-4.2/trunk/gcc/llvm-abi-default.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/llvm-abi-default.cpp?rev=139189&r1=139188&r2=139189&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/llvm-abi-default.cpp (original)
+++ llvm-gcc-4.2/trunk/gcc/llvm-abi-default.cpp Tue Sep 6 16:53:06 2011
@@ -117,7 +117,7 @@
Attribute::constructAlignmentFromInt(LLVM_BYVAL_ALIGNMENT(type));
}
}
- } else if (LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(type, Ty, C.getCallingConv())) {
+ } else if (LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(type, Ty)) {
C.HandleByValArgument(Ty, type);
if (Attributes) {
*Attributes |= Attribute::ByVal;
@@ -144,7 +144,7 @@
// (We know there currently are no other such cases active because
// they would hit the assert in FunctionPrologArgumentConversion::
// HandleByValArgument.)
- if (!LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(Ftype, FTy, C.getCallingConv())) {
+ if (!LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(Ftype, FTy)) {
C.EnterField(FNo, Ty);
HandleArgument(getDeclaredType(Field), ScalarElts);
C.ExitField();
Modified: llvm-gcc-4.2/trunk/gcc/llvm-abi.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/llvm-abi.h?rev=139189&r1=139188&r2=139189&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/llvm-abi.h (original)
+++ llvm-gcc-4.2/trunk/gcc/llvm-abi.h Tue Sep 6 16:53:06 2011
@@ -274,7 +274,7 @@
// value should be passed by value, i.e. passing its address with the byval
// attribute bit set. The default is false.
#ifndef LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR
-#define LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(X, TY, CC) \
+#define LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(X, TY) \
false
#endif
Modified: llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp?rev=139189&r1=139188&r2=139189&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp (original)
+++ llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp Tue Sep 6 16:53:06 2011
@@ -437,7 +437,7 @@
static bool isPassedByVal(tree type, Type *Ty,
std::vector<Type*> &ScalarArgs,
CallingConv::ID &CC) {
- if (LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(type, Ty, CC))
+ if (LLVM_SHOULD_PASS_AGGREGATE_USING_BYVAL_ATTR(type, Ty))
return true;
std::vector<Type*> Args;
More information about the llvm-commits
mailing list