().is64Bit();
> - unsigned FrameReg = is64Bit ? X86::RBP : X86::EBP;
>
> unsigned Opc = is64Bit ? X86::POP64r : X86::POP32r;
> for (unsigned i = 0, e = CSI.size(); i != e; ++i) {
> unsigned Reg = CSI[i].getReg();
> - if (Reg == FrameReg && RI.hasFP(MF))
> - // It will be restored as part of the epilogue.
> - continue;
> BuildMI(MBB, MI, get(Opc), Reg);
> }
> return true;
>
> Modified: llvm/trunk/test/CodeGen/X86/2008-08-31-EH_RETURN32.ll
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/2008-08-31-EH_RETURN32.ll?rev=57048&r1=57047&r2=57048&view=diff
>
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- llvm/trunk/test/CodeGen/X86/2008-08-31-EH_RETURN32.ll (original)
> +++ llvm/trunk/test/CodeGen/X86/2008-08-31-EH_RETURN32.ll Sat Oct 4
> 06:09:36 2008
> @@ -1,5 +1,5 @@
> ; Check that eh_return & unwind_init were properly lowered
> -; RUN: llvm-as < %s | llc | grep %ebp | count 7
> +; RUN: llvm-as < %s | llc | grep %ebp | count 9
> ; RUN: llvm-as < %s | llc | grep %ecx | count 5
>
> target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-
> i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64"
>
> Modified: llvm/trunk/test/CodeGen/X86/2008-08-31-EH_RETURN64.ll
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/2008-08-31-EH_RETURN64.ll?rev=57048&r1=57047&r2=57048&view=diff
>
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- llvm/trunk/test/CodeGen/X86/2008-08-31-EH_RETURN64.ll (original)
> +++ llvm/trunk/test/CodeGen/X86/2008-08-31-EH_RETURN64.ll Sat Oct 4
> 06:09:36 2008
> @@ -1,5 +1,5 @@
> ; Check that eh_return & unwind_init were properly lowered
> -; RUN: llvm-as < %s | llc | grep %rbp | count 5
> +; RUN: llvm-as < %s | llc | grep %rbp | count 7
> ; RUN: llvm-as < %s | llc | grep %rcx | count 3
>
> target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-
> i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-
> s0:64:64-f80:128:128"
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From dalej at apple.com Mon Oct 6 13:22:29 2008
From: dalej at apple.com (Dale Johannesen)
Date: Mon, 06 Oct 2008 18:22:29 -0000
Subject: [llvm-commits] [llvm] r57185 - /llvm/trunk/lib/Support/APFloat.cpp
Message-ID: <200810061822.m96IMTgD007250@zion.cs.uiuc.edu>
Author: johannes
Date: Mon Oct 6 13:22:29 2008
New Revision: 57185
URL: http://llvm.org/viewvc/llvm-project?rev=57185&view=rev
Log:
Mark shortening NaN conversions as Inexact. PR 2856.
Improve description of unsupported formats.
Modified:
llvm/trunk/lib/Support/APFloat.cpp
Modified: llvm/trunk/lib/Support/APFloat.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/APFloat.cpp?rev=57185&r1=57184&r2=57185&view=diff
==============================================================================
--- llvm/trunk/lib/Support/APFloat.cpp (original)
+++ llvm/trunk/lib/Support/APFloat.cpp Mon Oct 6 13:22:29 2008
@@ -1727,11 +1727,12 @@
APInt::tcShiftLeft(significandParts(), newPartCount, shift);
else if (shift < 0)
APInt::tcShiftRight(significandParts(), newPartCount, -shift);
+ // If the new size is shorter, we lost information.
+ fs = (shift < 0) ? opInexact : opOK;
// gcc forces the Quiet bit on, which means (float)(double)(float_sNan)
// does not give you back the same bits. This is dubious, and we
// don't currently do it. You're really supposed to get
// an invalid operation signal at runtime, but nobody does that.
- fs = opOK;
} else {
semantics = &toSemantics;
fs = opOK;
@@ -2633,11 +2634,13 @@
return api.bitsToDouble();
}
-/// Integer bit is explicit in this format. Current Intel book does not
-/// define meaning of:
-/// exponent = all 1's, integer bit not set.
-/// exponent = 0, integer bit set. (formerly "psuedodenormals")
-/// exponent!=0 nor all 1's, integer bit not set. (formerly "unnormals")
+/// Integer bit is explicit in this format. Intel hardware (387 and later)
+/// does not support these bit patterns:
+/// exponent = all 1's, integer bit 0, significand 0 ("pseudoinfinity")
+/// exponent = all 1's, integer bit 0, significand nonzero ("pseudoNaN")
+/// exponent = 0, integer bit 1 ("pseudodenormal")
+/// exponent!=0 nor all 1's, integer bit 0 ("unnormal")
+/// At the moment, the first two are treated as NaNs, the second two as Normal.
void
APFloat::initFromF80LongDoubleAPInt(const APInt &api)
{
From evan.cheng at apple.com Mon Oct 6 13:42:48 2008
From: evan.cheng at apple.com (Evan Cheng)
Date: Mon, 06 Oct 2008 18:42:48 -0000
Subject: [llvm-commits] [llvm] r57193 - in /llvm/trunk/test:
FrontendObjC++/2008-10-3-EhValue.mm FrontendObjC/2008-10-3-EhValue.mm
Message-ID: <200810061842.m96IgmVs008233@zion.cs.uiuc.edu>
Author: evancheng
Date: Mon Oct 6 13:42:48 2008
New Revision: 57193
URL: http://llvm.org/viewvc/llvm-project?rev=57193&view=rev
Log:
This is an objective-c test, not an objective-c++ one.
Added:
llvm/trunk/test/FrontendObjC/2008-10-3-EhValue.mm
Removed:
llvm/trunk/test/FrontendObjC++/2008-10-3-EhValue.mm
Removed: llvm/trunk/test/FrontendObjC++/2008-10-3-EhValue.mm
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/FrontendObjC%2B%2B/2008-10-3-EhValue.mm?rev=57192&view=auto
==============================================================================
--- llvm/trunk/test/FrontendObjC++/2008-10-3-EhValue.mm (original)
+++ llvm/trunk/test/FrontendObjC++/2008-10-3-EhValue.mm (removed)
@@ -1,50 +0,0 @@
-// RUN: %llvmgcc -w -x objective-c++ -c %s -o /dev/null
-
- at interface Object {
- at public
- Class isa;
-}
-+initialize;
-+alloc;
-+new;
-+free;
--free;
-+(Class)class;
--(Class)class;
--init;
--superclass;
--(const char *)name;
- at end
-
- at interface Frob: Object
- at end
-
- at implementation Frob: Object
- at end
-
-static Frob* _connection = ((void *)0);
-
-extern void abort(void);
-
-void test (Object* sendPort)
-{
- int cleanupPorts = 1;
- Frob* receivePort = ((void *)0);
-
- @try {
- receivePort = (Frob *) -1;
- _connection = (Frob *) -1;
- receivePort = ((void *)0);
- sendPort = ((void *)0);
- cleanupPorts = 0;
- @throw [Object new];
- }
- @catch(Frob *obj) {
- if(!(0)) abort();
- }
- @catch(id exc) {
- if(!(!receivePort)) abort();
- if(!(!sendPort)) abort();
- if(!(!cleanupPorts)) abort();
- }
-}
Added: llvm/trunk/test/FrontendObjC/2008-10-3-EhValue.mm
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/FrontendObjC/2008-10-3-EhValue.mm?rev=57193&view=auto
==============================================================================
--- llvm/trunk/test/FrontendObjC/2008-10-3-EhValue.mm (added)
+++ llvm/trunk/test/FrontendObjC/2008-10-3-EhValue.mm Mon Oct 6 13:42:48 2008
@@ -0,0 +1,50 @@
+// RUN: %llvmgcc -w -x objective-c -c %s -o /dev/null
+
+ at interface Object {
+ at public
+ Class isa;
+}
++initialize;
++alloc;
++new;
++free;
+-free;
++(Class)class;
+-(Class)class;
+-init;
+-superclass;
+-(const char *)name;
+ at end
+
+ at interface Frob: Object
+ at end
+
+ at implementation Frob: Object
+ at end
+
+static Frob* _connection = ((void *)0);
+
+extern void abort(void);
+
+void test (Object* sendPort)
+{
+ int cleanupPorts = 1;
+ Frob* receivePort = ((void *)0);
+
+ @try {
+ receivePort = (Frob *) -1;
+ _connection = (Frob *) -1;
+ receivePort = ((void *)0);
+ sendPort = ((void *)0);
+ cleanupPorts = 0;
+ @throw [Object new];
+ }
+ @catch(Frob *obj) {
+ if(!(0)) abort();
+ }
+ @catch(id exc) {
+ if(!(!receivePort)) abort();
+ if(!(!sendPort)) abort();
+ if(!(!cleanupPorts)) abort();
+ }
+}
From dpatel at apple.com Mon Oct 6 13:50:38 2008
From: dpatel at apple.com (Devang Patel)
Date: Mon, 06 Oct 2008 18:50:38 -0000
Subject: [llvm-commits] [llvm] r57197 - /llvm/trunk/docs/LangRef.html
Message-ID: <200810061850.m96Ioc1e008536@zion.cs.uiuc.edu>
Author: dpatel
Date: Mon Oct 6 13:50:38 2008
New Revision: 57197
URL: http://llvm.org/viewvc/llvm-project?rev=57197&view=rev
Log:
Update function attributes docs.
Modified:
llvm/trunk/docs/LangRef.html
Modified: llvm/trunk/docs/LangRef.html
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/LangRef.html?rev=57197&r1=57196&r2=57197&view=diff
==============================================================================
--- llvm/trunk/docs/LangRef.html (original)
+++ llvm/trunk/docs/LangRef.html Mon Oct 6 13:50:38 2008
@@ -749,8 +749,9 @@
calling convention, a return type, an optional
parameter attribute for the return type, a function
name, a (possibly empty) argument list (each with optional
-parameter attributes), an optional section, an
-optional alignment, an optional garbage collector name,
+parameter attributes), optional
+function attributes, an optional section,
+an optional alignment, an optional garbage collector name,
an opening curly brace, a list of basic blocks, and a closing curly brace.
LLVM function declarations consist of the "declare" keyword, an
@@ -861,23 +862,27 @@
value, but is also valid on pointers to scalars. The copy is considered to
belong to the caller not the callee (for example,
readonly functions should not write to
- byval parameters).
+ byval parameters). This is not a valid attribute for return
+ values.
sret
This indicates that the pointer parameter specifies the address of a
structure that is the return value of the function in the source program.
This pointer must be guaranteed by the caller to be valid: loads and stores
to the structure may be assumed by the callee to not to trap. This may only
- be applied to the first parameter.
+ be applied to the first parameter. This is not a valid attribute for
+ return values.
noalias
This indicates that the parameter does not alias any global or any other
parameter. The caller is responsible for ensuring that this is the case,
- usually by placing the value in a stack allocation.
+ usually by placing the value in a stack allocation. This is not a valid
+ attribute for return values.
nest
This indicates that the pointer parameter can be excised using the
- trampoline intrinsics.
+ trampoline intrinsics. This is not a valid
+ attribute for return values.
@@ -2041,7 +2046,8 @@
Syntax:
- <result> = invoke [cconv] <ptr to function ty> <function ptr val>(<function args>)
+ <result> = invoke [cconv] [RetAttrs] <ptr to function ty> <function ptr val>(<function args>)
to label <normal label> unwind label <exception label>
@@ -2066,6 +2072,11 @@
convention the call should use. If none is specified, the call defaults
to using C calling conventions.
+
+ The optional Parameter Attributes list for
+ return values. Only 'zeroext', 'signext',
+ and 'inreg' attributes are valid here.
+
'ptr to function ty': shall be the signature of the pointer to
function value being invoked. In most cases, this is a direct function
invocation, but indirect invokes are just as possible, branching off
@@ -2086,6 +2097,9 @@
'exception label': the label reached when a callee returns with
the unwind instruction.
+ The optional function attributes list. Only
+ 'noreturn', 'nounwind', 'readonly' and
+ 'readnone' attributes are valid here.
Semantics:
@@ -4235,7 +4249,7 @@
Syntax:
- <result> = [tail] call [cconv] <ty> [<fnty>*] <fnptrval>(<param list>)
+ <result> = [tail] call [cconv] [RetAttrs] <ty> [<fnty>*] <fnptrval>(<param list>)
Overview:
@@ -4259,6 +4273,13 @@
convention the call should use. If none is specified, the call defaults
to using C calling conventions.
+
+
+ The optional Parameter Attributes list for
+ return values. Only 'zeroext', 'signext',
+ and 'inreg' attributes are valid here.
+
+
'ty': the type of the call instruction itself which is also
the type of the return value. Functions that return no value are marked
@@ -4283,6 +4304,11 @@
indicates the function accepts a variable number of arguments, the extra
arguments can be specified.
+
+ The optional function attributes list. Only
+ 'noreturn', 'nounwind', 'readonly' and
+ 'readnone' attributes are valid here.
+
Semantics:
@@ -4304,9 +4330,11 @@
call void %foo(i8 97 signext)
%struct.A = type { i32, i8 }
- %r = call %struct.A @foo() ; yields { 32, i8 }
+ %r = call %struct.A @foo() ; yields { 32, i8 }
%gr = extractvalue %struct.A %r, 0 ; yields i32
%gr1 = extractvalue %struct.A %r, 1 ; yields i8
+ %Z = call void @foo() noreturn ; indicates that foo never returns nomrally
+ %ZZ = call zeroext i32 @bar() ; Return value is zero extended
From gohman at apple.com Mon Oct 6 13:51:23 2008
From: gohman at apple.com (Dan Gohman)
Date: Mon, 6 Oct 2008 11:51:23 -0700
Subject: [llvm-commits] [llvm] r57185 -
/llvm/trunk/lib/Support/APFloat.cpp
In-Reply-To: <200810061822.m96IMTgD007250@zion.cs.uiuc.edu>
References: <200810061822.m96IMTgD007250@zion.cs.uiuc.edu>
Message-ID:
On Oct 6, 2008, at 11:22 AM, Dale Johannesen wrote:
> Author: johannes
> Date: Mon Oct 6 13:22:29 2008
> New Revision: 57185
>
> URL: http://llvm.org/viewvc/llvm-project?rev=57185&view=rev
> Log:
> Mark shortening NaN conversions as Inexact. PR 2856.
> Improve description of unsupported formats.
>
>
> Modified:
> llvm/trunk/lib/Support/APFloat.cpp
>
> Modified: llvm/trunk/lib/Support/APFloat.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/APFloat.cpp?rev=57185&r1=57184&r2=57185&view=diff
>
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- llvm/trunk/lib/Support/APFloat.cpp (original)
> +++ llvm/trunk/lib/Support/APFloat.cpp Mon Oct 6 13:22:29 2008
> @@ -1727,11 +1727,12 @@
> APInt::tcShiftLeft(significandParts(), newPartCount, shift);
> else if (shift < 0)
> APInt::tcShiftRight(significandParts(), newPartCount, -shift);
> + // If the new size is shorter, we lost information.
> + fs = (shift < 0) ? opInexact : opOK;
> // gcc forces the Quiet bit on, which means (float)(double)
> (float_sNan)
> // does not give you back the same bits. This is dubious, and we
> // don't currently do it. You're really supposed to get
> // an invalid operation signal at runtime, but nobody does that.
> - fs = opOK;
Shouldn't converting a NaN set the opInvalidOp flag?
Dan
From anton at korobeynikov.info Mon Oct 6 13:58:07 2008
From: anton at korobeynikov.info (Anton Korobeynikov)
Date: Mon, 6 Oct 2008 22:58:07 +0400
Subject: [llvm-commits] [llvm] r57048 - in /llvm/trunk:
lib/Target/X86/X86InstrInfo.cpp
test/CodeGen/X86/2008-08-31-EH_RETURN32.ll
test/CodeGen/X86/2008-08-31-EH_RETURN64.ll
In-Reply-To:
References: <200810041109.m94B9dL9019148@zion.cs.uiuc.edu>
Message-ID:
Hi, Evan
> Is the second push of ebp necessary?
Surely, no. I didn't dig into problem deep enough for now.
Maybe some information about callee-saved registers and their offsets
are not updated properly? And this makes unwinding runtime unhappy
somehow...
--
With best regards, Anton Korobeynikov
Faculty of Mathematics and Mechanics, Saint Petersburg State University
From baldrick at free.fr Mon Oct 6 14:10:04 2008
From: baldrick at free.fr (Duncan Sands)
Date: Mon, 6 Oct 2008 21:10:04 +0200
Subject: [llvm-commits] [llvm] r57048 - in /llvm/trunk:
lib/Target/X86/X86InstrInfo.cpp
test/CodeGen/X86/2008-08-31-EH_RETURN32.ll
test/CodeGen/X86/2008-08-31-EH_RETURN64.ll
In-Reply-To:
References: <200810041109.m94B9dL9019148@zion.cs.uiuc.edu>
Message-ID: <200810062110.04381.baldrick@free.fr>
Hi Evan,
> Do you know why it's breaking unwinding? With the patch backed out,
> it's generating:
in the testcase where I saw breakage, the problem was due to
a miscompilation of llvm-gcc's libgcc (shared version). In
fact the application itself (which did a lot of throwing and
catching) worked fine when compiled with llvm-gcc as long as
it was linked with the system libgcc, not llvm-gcc's libgcc.
So it looks like your patch works fine almost always, only
there's something subtle in libgcc which it breaks.
Ciao,
Duncan.
From anton at korobeynikov.info Mon Oct 6 14:21:27 2008
From: anton at korobeynikov.info (Anton Korobeynikov)
Date: Mon, 6 Oct 2008 23:21:27 +0400
Subject: [llvm-commits] [llvm] r57048 - in /llvm/trunk:
lib/Target/X86/X86InstrInfo.cpp
test/CodeGen/X86/2008-08-31-EH_RETURN32.ll
test/CodeGen/X86/2008-08-31-EH_RETURN64.ll
In-Reply-To: <200810062110.04381.baldrick@free.fr>
References: <200810041109.m94B9dL9019148@zion.cs.uiuc.edu>
<200810062110.04381.baldrick@free.fr>
Message-ID:
Hi, Duncan
> in the testcase where I saw breakage, the problem was due to
> a miscompilation of llvm-gcc's libgcc (shared version). In
Same for me. However, static one was also miscompiled.
> So it looks like your patch works fine almost always, only
> there's something subtle in libgcc which it breaks.
Yep. I saw a segfault inside _Unwind_Resume, due to access to invalid
address. AFAIR, ebp was not restored properly after unwind or
something like this.
--
With best regards, Anton Korobeynikov
Faculty of Mathematics and Mechanics, Saint Petersburg State University
From evan.cheng at apple.com Mon Oct 6 15:06:05 2008
From: evan.cheng at apple.com (Evan Cheng)
Date: Mon, 06 Oct 2008 20:06:05 -0000
Subject: [llvm-commits] [llvm-gcc-4.2] r57199 -
/llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
Message-ID: <200810062006.m96K656I011430@zion.cs.uiuc.edu>
Author: evancheng
Date: Mon Oct 6 15:06:02 2008
New Revision: 57199
URL: http://llvm.org/viewvc/llvm-project?rev=57199&view=rev
Log:
Apply Duncan's patch which does what r57022 does but in a much cleaner way.
Modified:
llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
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=57199&r1=57198&r2=57199&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp (original)
+++ llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp Mon Oct 6 15:06:02 2008
@@ -2746,19 +2746,8 @@
}
Attributes Attrs = Attribute::None;
- // See EmitEXC_PTR_EXPR and EmitFILTER_EXPR. Rather than handle the
- // arguments themselves, process eh_value and eh_select.
- if (TREE_CODE(TREE_VALUE(arg)) == EXC_PTR_EXPR) {
- const Type *Ty = ExceptionValue->getType();
- Ty = cast(Ty)->getElementType();
- Client.HandleScalarArgument(Ty, 0);
- } else if (TREE_CODE(TREE_VALUE(arg)) == FILTER_EXPR) {
- const Type *Ty = ExceptionSelectorValue->getType();
- Ty = cast(Ty)->getElementType();
- Client.HandleScalarArgument(Ty, 0);
- } else
- ABIConverter.HandleArgument(TREE_TYPE(TREE_VALUE(arg)), ScalarArgs,
- &Attrs);
+ ABIConverter.HandleArgument(TREE_TYPE(TREE_VALUE(arg)), ScalarArgs,
+ &Attrs);
if (Attrs != Attribute::None)
PAL = PAL.addAttr(CallOperands.size(), Attrs);
@@ -3749,14 +3738,18 @@
Value *TreeToLLVM::EmitEXC_PTR_EXPR(tree exp) {
CreateExceptionValues();
// Load exception address.
- return Builder.CreateLoad(ExceptionValue, "eh_value");
+ Value *V = Builder.CreateLoad(ExceptionValue, "eh_value");
+ // Cast the address to the right pointer type.
+ return BitCastToType(V, ConvertType(TREE_TYPE(exp)));
}
/// EmitFILTER_EXPR - Handle FILTER_EXPR.
Value *TreeToLLVM::EmitFILTER_EXPR(tree exp) {
CreateExceptionValues();
// Load exception selector.
- return Builder.CreateLoad(ExceptionSelectorValue, "eh_select");
+ Value *V = Builder.CreateLoad(ExceptionSelectorValue, "eh_select");
+ // Cast the address to the right pointer type.
+ return BitCastToType(V, ConvertType(TREE_TYPE(exp)));
}
/// EmitRESX_EXPR - Handle RESX_EXPR.
@@ -6190,12 +6183,15 @@
LValue TreeToLLVM::EmitLV_EXC_PTR_EXPR(tree exp) {
CreateExceptionValues();
- return ExceptionValue;
+ // Cast the address pointer to the expected type.
+ return BitCastToType(ExceptionValue,
+ PointerType::getUnqual(ConvertType(TREE_TYPE(exp))));
}
LValue TreeToLLVM::EmitLV_FILTER_EXPR(tree exp) {
CreateExceptionValues();
- return ExceptionSelectorValue;
+ return BitCastToType(ExceptionSelectorValue,
+ PointerType::getUnqual(ConvertType(TREE_TYPE(exp))));
}
//===----------------------------------------------------------------------===//
From evan.cheng at apple.com Mon Oct 6 15:06:34 2008
From: evan.cheng at apple.com (Evan Cheng)
Date: Mon, 6 Oct 2008 13:06:34 -0700
Subject: [llvm-commits] [llvm-gcc-4.2] r57022 -
/llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
In-Reply-To: <200810061437.57014.baldrick@free.fr>
References: <200810031805.m93I5gFh007073@zion.cs.uiuc.edu>
<200810061437.57014.baldrick@free.fr>
Message-ID: <17B43EAC-EFCA-4919-8DDF-9D5D21C33810@apple.com>
Thanks. It works. I've applied the patch, along with changes for
FILTER_EXPR.
Evan
On Oct 6, 2008, at 5:37 AM, Duncan Sands wrote:
> Hi Evan,
>
>> Fix a bug in EmitCallOf which shows up only with assertion turned
>> on. When it's processing a call argument that corresponds to
>> eh_value or eh_select, grab the type of special variables
>> ExceptionValue or ExceptionSelectorValue instead or it won't match
>> the expected type.
>>
>> With assertion turned off, this bug doesn't cause any
>> miscompilation because pointer types are *compatible*. But it's a
>> bug anyway.
>
> I think the reason for this is while the generic code builds
> EXC_PTR_EXPR as a void*:
>
> tree-eh.c: x = build0 (EXC_PTR_EXPR, ptr_type_node);
>
> the objc (not obj-c++) front-end builds it as an objc_object_type:
>
> objc-act.c: return build0 (EXC_PTR_EXPR, objc_object_type);
>
> So the thing to do is simply bitcast to the right type in
> llvm-convert. Based on this theory, can you please test the
> attached patch for me (the testcase doesn't compile here, even
> though I built with obj-c++ support...).
>
> Thanks,
>
> Duncan.
>
> PS: There shouldn't be any issue with FILTER_EXPR as far as I can see.
>
From evan.cheng at apple.com Mon Oct 6 15:10:44 2008
From: evan.cheng at apple.com (Evan Cheng)
Date: Mon, 6 Oct 2008 13:10:44 -0700
Subject: [llvm-commits] [llvm] r57023 -
/llvm/trunk/test/FrontendObjC++/2008-10-3-EhValue.mm
In-Reply-To: <200810061233.24739.baldrick@free.fr>
References: <200810031812.m93ICxxF007306@zion.cs.uiuc.edu>
<200810061233.24739.baldrick@free.fr>
Message-ID: <633E2B90-31A3-4C9C-86A5-109440BA11CD@apple.com>
Fixed. Thanks.
Evan
On Oct 6, 2008, at 3:33 AM, Duncan Sands wrote:
> Hi Evan,
>
>> Added:
>> llvm/trunk/test/FrontendObjC++/2008-10-3-EhValue.mm
>
> this test fails for me (x86-32 linux) with
> test/FrontendObjC++/2008-10-3-EhValue.mm:25: error: invalid
> conversion from 'void*' to 'Frob*'
> test/FrontendObjC++/2008-10-3-EhValue.mm: In function 'void
> test(Object*)':
> test/FrontendObjC++/2008-10-3-EhValue.mm:32: error: invalid
> conversion from 'void*' to 'Frob*'
> test/FrontendObjC++/2008-10-3-EhValue.mm:37: error: invalid
> conversion from 'void*' to 'Frob*'
> test/FrontendObjC++/2008-10-3-EhValue.mm:38: error: invalid
> conversion from 'void*' to 'Object*'
> so I was unable to reproduce the problem you fixed (I want to
> fix it differently).
>
> Ciao,
>
> Duncan.
>
> PS: Maybe it fails for you too now I fixed the testsuite to actually
> run Obj-C++ tests :)
>
From evan.cheng at apple.com Mon Oct 6 15:14:36 2008
From: evan.cheng at apple.com (Evan Cheng)
Date: Mon, 6 Oct 2008 13:14:36 -0700
Subject: [llvm-commits] [llvm] r57048 - in /llvm/trunk:
lib/Target/X86/X86InstrInfo.cpp
test/CodeGen/X86/2008-08-31-EH_RETURN32.ll
test/CodeGen/X86/2008-08-31-EH_RETURN64.ll
In-Reply-To: <200810062110.04381.baldrick@free.fr>
References: <200810041109.m94B9dL9019148@zion.cs.uiuc.edu>
<200810062110.04381.baldrick@free.fr>
Message-ID:
Ok. Can you guys look into this? I don't have the unwinding expertise.
I think it's fine to ignore the performance issue for this release.
Thanks,
Evan
On Oct 6, 2008, at 12:10 PM, Duncan Sands wrote:
> Hi Evan,
>
>> Do you know why it's breaking unwinding? With the patch backed out,
>> it's generating:
>
> in the testcase where I saw breakage, the problem was due to
> a miscompilation of llvm-gcc's libgcc (shared version). In
> fact the application itself (which did a lot of throwing and
> catching) worked fine when compiled with llvm-gcc as long as
> it was linked with the system libgcc, not llvm-gcc's libgcc.
> So it looks like your patch works fine almost always, only
> there's something subtle in libgcc which it breaks.
>
> Ciao,
>
> Duncan.
From dalej at apple.com Mon Oct 6 15:23:29 2008
From: dalej at apple.com (Dale Johannesen)
Date: Mon, 6 Oct 2008 13:23:29 -0700
Subject: [llvm-commits] [llvm] r57185
- /llvm/trunk/lib/Support/APFloat.cpp
In-Reply-To:
References: <200810061822.m96IMTgD007250@zion.cs.uiuc.edu>
Message-ID: <0C450614-92AA-4337-B0EA-53797DA53326@apple.com>
On Oct 6, 2008, at 11:51 AMPDT, Dan Gohman wrote:
>>
>> + fs = (shift < 0) ? opInexact : opOK;
>> // gcc forces the Quiet bit on, which means (float)(double)
>> (float_sNan)
>> // does not give you back the same bits. This is dubious, and we
>> // don't currently do it. You're really supposed to get
>> // an invalid operation signal at runtime, but nobody does that.
>> - fs = opOK;
>
> Shouldn't converting a NaN set the opInvalidOp flag?
According to IEEE754, converting a SNan sets opInvalid, but we aren't
really trying for an accurate implementation of SNan's (nor does the
OS).
For converting a QNan, what it says is:
"Every operation involving one or two input NaNs, none of them
signaling, shall signal no exception but, if a FP result is to be
delivered, shall deliver as its result a QNaN, which should be one of
the input NaNs. Note that format conversions might be unable to
deliver the same NaN."
The last sentence applies here, and I'm not sure of its intent. At
face value it's a statement that it may be impossible to implement the
standard in this case, which seems unlikely. IMO an Inexact result
seems compatible with the way things work otherwise.
To confuse things further, the value in the PR is not even an IEEE
NaN, but a pseudo-NaN in Intel jargon. It is outside all standards.
From gohman at apple.com Mon Oct 6 15:20:23 2008
From: gohman at apple.com (Dan Gohman)
Date: Mon, 6 Oct 2008 13:20:23 -0700
Subject: [llvm-commits] [llvm] r57185 -
/llvm/trunk/lib/Support/APFloat.cpp
In-Reply-To: <200810061822.m96IMTgD007250@zion.cs.uiuc.edu>
References: <200810061822.m96IMTgD007250@zion.cs.uiuc.edu>
Message-ID: <19EA1798-D3FB-4365-B537-0A2ABA3F72F6@apple.com>
Hi Dale,
This is causing these tests:
CodeGen/X86/all-ones-vector.ll
CodeGen/CBackend/2003-10-12-NANGlobalInits.ll
to fail with error message "Floating point constant invalid for type"
from llvm-as. Can you investigate?
Thanks,
Dan
On Oct 6, 2008, at 11:22 AM, Dale Johannesen wrote:
> Author: johannes
> Date: Mon Oct 6 13:22:29 2008
> New Revision: 57185
>
> URL: http://llvm.org/viewvc/llvm-project?rev=57185&view=rev
> Log:
> Mark shortening NaN conversions as Inexact. PR 2856.
> Improve description of unsupported formats.
>
>
> Modified:
> llvm/trunk/lib/Support/APFloat.cpp
>
> Modified: llvm/trunk/lib/Support/APFloat.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/APFloat.cpp?rev=57185&r1=57184&r2=57185&view=diff
>
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- llvm/trunk/lib/Support/APFloat.cpp (original)
> +++ llvm/trunk/lib/Support/APFloat.cpp Mon Oct 6 13:22:29 2008
> @@ -1727,11 +1727,12 @@
> APInt::tcShiftLeft(significandParts(), newPartCount, shift);
> else if (shift < 0)
> APInt::tcShiftRight(significandParts(), newPartCount, -shift);
> + // If the new size is shorter, we lost information.
> + fs = (shift < 0) ? opInexact : opOK;
> // gcc forces the Quiet bit on, which means (float)(double)
> (float_sNan)
> // does not give you back the same bits. This is dubious, and we
> // don't currently do it. You're really supposed to get
> // an invalid operation signal at runtime, but nobody does that.
> - fs = opOK;
> } else {
> semantics = &toSemantics;
> fs = opOK;
> @@ -2633,11 +2634,13 @@
> return api.bitsToDouble();
> }
>
> -/// Integer bit is explicit in this format. Current Intel book
> does not
> -/// define meaning of:
> -/// exponent = all 1's, integer bit not set.
> -/// exponent = 0, integer bit set. (formerly "psuedodenormals")
> -/// exponent!=0 nor all 1's, integer bit not set. (formerly
> "unnormals")
> +/// Integer bit is explicit in this format. Intel hardware (387
> and later)
> +/// does not support these bit patterns:
> +/// exponent = all 1's, integer bit 0, significand 0
> ("pseudoinfinity")
> +/// exponent = all 1's, integer bit 0, significand nonzero
> ("pseudoNaN")
> +/// exponent = 0, integer bit 1 ("pseudodenormal")
> +/// exponent!=0 nor all 1's, integer bit 0 ("unnormal")
> +/// At the moment, the first two are treated as NaNs, the second
> two as Normal.
> void
> APFloat::initFromF80LongDoubleAPInt(const APInt &api)
> {
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From dalej at apple.com Mon Oct 6 15:30:25 2008
From: dalej at apple.com (Dale Johannesen)
Date: Mon, 6 Oct 2008 13:30:25 -0700
Subject: [llvm-commits] [llvm] r57185
- /llvm/trunk/lib/Support/APFloat.cpp
In-Reply-To: <19EA1798-D3FB-4365-B537-0A2ABA3F72F6@apple.com>
References: <200810061822.m96IMTgD007250@zion.cs.uiuc.edu>
<19EA1798-D3FB-4365-B537-0A2ABA3F72F6@apple.com>
Message-ID: <01B61E2A-DAF6-49A3-B6A2-7CC208E7B0D3@apple.com>
On Oct 6, 2008, at 1:20 PMPDT, Dan Gohman wrote:
> Hi Dale,
>
> This is causing these tests:
>
> CodeGen/X86/all-ones-vector.ll
> CodeGen/CBackend/2003-10-12-NANGlobalInits.ll
>
> to fail with error message "Floating point constant invalid for type"
> from llvm-as. Can you investigate?
OK.
>
> Thanks,
>
> Dan
>
> On Oct 6, 2008, at 11:22 AM, Dale Johannesen wrote:
>
>> Author: johannes
>> Date: Mon Oct 6 13:22:29 2008
>> New Revision: 57185
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=57185&view=rev
>> Log:
>> Mark shortening NaN conversions as Inexact. PR 2856.
>> Improve description of unsupported formats.
>>
>>
>> Modified:
>> llvm/trunk/lib/Support/APFloat.cpp
>>
>> Modified: llvm/trunk/lib/Support/APFloat.cpp
>> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/APFloat.cpp?rev=57185&r1=57184&r2=57185&view=diff
>>
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =====================================================================
>> --- llvm/trunk/lib/Support/APFloat.cpp (original)
>> +++ llvm/trunk/lib/Support/APFloat.cpp Mon Oct 6 13:22:29 2008
>> @@ -1727,11 +1727,12 @@
>> APInt::tcShiftLeft(significandParts(), newPartCount, shift);
>> else if (shift < 0)
>> APInt::tcShiftRight(significandParts(), newPartCount, -shift);
>> + // If the new size is shorter, we lost information.
>> + fs = (shift < 0) ? opInexact : opOK;
>> // gcc forces the Quiet bit on, which means (float)(double)
>> (float_sNan)
>> // does not give you back the same bits. This is dubious, and we
>> // don't currently do it. You're really supposed to get
>> // an invalid operation signal at runtime, but nobody does that.
>> - fs = opOK;
>> } else {
>> semantics = &toSemantics;
>> fs = opOK;
>> @@ -2633,11 +2634,13 @@
>> return api.bitsToDouble();
>> }
>>
>> -/// Integer bit is explicit in this format. Current Intel book
>> does not
>> -/// define meaning of:
>> -/// exponent = all 1's, integer bit not set.
>> -/// exponent = 0, integer bit set. (formerly "psuedodenormals")
>> -/// exponent!=0 nor all 1's, integer bit not set. (formerly
>> "unnormals")
>> +/// Integer bit is explicit in this format. Intel hardware (387
>> and later)
>> +/// does not support these bit patterns:
>> +/// exponent = all 1's, integer bit 0, significand 0
>> ("pseudoinfinity")
>> +/// exponent = all 1's, integer bit 0, significand nonzero
>> ("pseudoNaN")
>> +/// exponent = 0, integer bit 1 ("pseudodenormal")
>> +/// exponent!=0 nor all 1's, integer bit 0 ("unnormal")
>> +/// At the moment, the first two are treated as NaNs, the second
>> two as Normal.
>> void
>> APFloat::initFromF80LongDoubleAPInt(const APInt &api)
>> {
>>
>>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From evan.cheng at apple.com Mon Oct 6 15:33:03 2008
From: evan.cheng at apple.com (Evan Cheng)
Date: Mon, 06 Oct 2008 20:33:03 -0000
Subject: [llvm-commits] [llvm] r57200 -
/llvm/trunk/include/llvm/Instruction.def
Message-ID: <200810062033.m96KX3nv012471@zion.cs.uiuc.edu>
Author: evancheng
Date: Mon Oct 6 15:33:02 2008
New Revision: 57200
URL: http://llvm.org/viewvc/llvm-project?rev=57200&view=rev
Log:
Cosmetic.
Modified:
llvm/trunk/include/llvm/Instruction.def
Modified: llvm/trunk/include/llvm/Instruction.def
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Instruction.def?rev=57200&r1=57199&r2=57200&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Instruction.def (original)
+++ llvm/trunk/include/llvm/Instruction.def Mon Oct 6 15:33:02 2008
@@ -117,7 +117,7 @@
// Logical operators (integer operands)
HANDLE_BINARY_INST(16, Shl , BinaryOperator) // Shift left (logical)
HANDLE_BINARY_INST(17, LShr , BinaryOperator) // Shift right (logical)
-HANDLE_BINARY_INST(18, AShr , BinaryOperator) // shift right (arithmetic)
+HANDLE_BINARY_INST(18, AShr , BinaryOperator) // Shift right (arithmetic)
HANDLE_BINARY_INST(19, And , BinaryOperator)
HANDLE_BINARY_INST(20, Or , BinaryOperator)
HANDLE_BINARY_INST(21, Xor , BinaryOperator)
From dpatel at apple.com Mon Oct 6 15:36:36 2008
From: dpatel at apple.com (Devang Patel)
Date: Mon, 06 Oct 2008 20:36:36 -0000
Subject: [llvm-commits] [llvm] r57202 - in /llvm/trunk:
lib/VMCore/PassManager.cpp test/Other/2008-10-06-RemoveDeadPass.ll
Message-ID: <200810062036.m96KaapP012605@zion.cs.uiuc.edu>
Author: dpatel
Date: Mon Oct 6 15:36:36 2008
New Revision: 57202
URL: http://llvm.org/viewvc/llvm-project?rev=57202&view=rev
Log:
Remove interfaces implemented by dead pass from the list of available passes.
Patch By Matthijs Kooijman.
Added:
llvm/trunk/test/Other/2008-10-06-RemoveDeadPass.ll
Modified:
llvm/trunk/lib/VMCore/PassManager.cpp
Modified: llvm/trunk/lib/VMCore/PassManager.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/VMCore/PassManager.cpp?rev=57202&r1=57201&r2=57202&view=diff
==============================================================================
--- llvm/trunk/lib/VMCore/PassManager.cpp (original)
+++ llvm/trunk/lib/VMCore/PassManager.cpp Mon Oct 6 15:36:36 2008
@@ -779,13 +779,23 @@
if (TheTimeInfo) TheTimeInfo->passStarted(*I);
(*I)->releaseMemory();
if (TheTimeInfo) TheTimeInfo->passEnded(*I);
-
- std::map::iterator Pos =
- AvailableAnalysis.find((*I)->getPassInfo());
-
- // It is possible that pass is already removed from the AvailableAnalysis
- if (Pos != AvailableAnalysis.end())
- AvailableAnalysis.erase(Pos);
+ if (const PassInfo *PI = (*I)->getPassInfo()) {
+ std::map::iterator Pos =
+ AvailableAnalysis.find(PI);
+
+ // It is possible that pass is already removed from the AvailableAnalysis
+ if (Pos != AvailableAnalysis.end())
+ AvailableAnalysis.erase(Pos);
+
+ // Remove all interfaces this pass implements, for which it is also
+ // listed as the available implementation.
+ const std::vector &II = PI->getInterfacesImplemented();
+ for (unsigned i = 0, e = II.size(); i != e; ++i) {
+ Pos = AvailableAnalysis.find(II[i]);
+ if (Pos != AvailableAnalysis.end() && Pos->second == *I)
+ AvailableAnalysis.erase(Pos);
+ }
+ }
}
}
Added: llvm/trunk/test/Other/2008-10-06-RemoveDeadPass.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Other/2008-10-06-RemoveDeadPass.ll?rev=57202&view=auto
==============================================================================
--- llvm/trunk/test/Other/2008-10-06-RemoveDeadPass.ll (added)
+++ llvm/trunk/test/Other/2008-10-06-RemoveDeadPass.ll Mon Oct 6 15:36:36 2008
@@ -0,0 +1,11 @@
+; RUN: llvm-as < %s | opt -inline -internalize -disable-output
+define void @foo() nounwind {
+ ret void
+}
+
+define void @main(...) nounwind {
+ call void @foo()
+ ret void
+}
+
+
From dpatel at apple.com Mon Oct 6 15:36:42 2008
From: dpatel at apple.com (Devang Patel)
Date: Mon, 6 Oct 2008 13:36:42 -0700
Subject: [llvm-commits] Patch to update available analysis correctly
In-Reply-To: <20081006140706.GA6091@katherina.student.utwente.nl>
References: <20081006140706.GA6091@katherina.student.utwente.nl>
Message-ID: <210A0DC3-A7E8-4653-B135-0290BC43157B@apple.com>
Hi Matthijs,
On Oct 6, 2008, at 7:07 AM, Matthijs Kooijman wrote:
> In any case, I think this is good to fix, and probably to get into
> 2.4 as
> well. I won't be able to commit this until next monday, so please
> commit the
> patch if you think it is correct.
>
> Gr.
Your patch looks good. Applied.
Thanks!
-
Devang
From dalej at apple.com Mon Oct 6 15:43:48 2008
From: dalej at apple.com (Dale Johannesen)
Date: Mon, 06 Oct 2008 20:43:48 -0000
Subject: [llvm-commits] [llvm] r57203 - /llvm/trunk/lib/Support/APFloat.cpp
Message-ID: <200810062043.m96KhmKh012859@zion.cs.uiuc.edu>
Author: johannes
Date: Mon Oct 6 15:43:48 2008
New Revision: 57203
URL: http://llvm.org/viewvc/llvm-project?rev=57203&view=rev
Log:
Temporarily revert functionality change from my previous patch;
it is too aggressive.
Modified:
llvm/trunk/lib/Support/APFloat.cpp
Modified: llvm/trunk/lib/Support/APFloat.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/APFloat.cpp?rev=57203&r1=57202&r2=57203&view=diff
==============================================================================
--- llvm/trunk/lib/Support/APFloat.cpp (original)
+++ llvm/trunk/lib/Support/APFloat.cpp Mon Oct 6 15:43:48 2008
@@ -1727,12 +1727,11 @@
APInt::tcShiftLeft(significandParts(), newPartCount, shift);
else if (shift < 0)
APInt::tcShiftRight(significandParts(), newPartCount, -shift);
- // If the new size is shorter, we lost information.
- fs = (shift < 0) ? opInexact : opOK;
// gcc forces the Quiet bit on, which means (float)(double)(float_sNan)
// does not give you back the same bits. This is dubious, and we
// don't currently do it. You're really supposed to get
// an invalid operation signal at runtime, but nobody does that.
+ fs = opOK;
} else {
semantics = &toSemantics;
fs = opOK;
From evan.cheng at apple.com Mon Oct 6 16:13:09 2008
From: evan.cheng at apple.com (Evan Cheng)
Date: Mon, 06 Oct 2008 21:13:09 -0000
Subject: [llvm-commits] [llvm] r57210 - in /llvm/trunk:
lib/Target/X86/X86ISelLowering.cpp
test/CodeGen/X86/2008-10-06-MMXISelBug.ll
Message-ID: <200810062113.m96LD9FB014314@zion.cs.uiuc.edu>
Author: evancheng
Date: Mon Oct 6 16:13:08 2008
New Revision: 57210
URL: http://llvm.org/viewvc/llvm-project?rev=57210&view=rev
Log:
Fix PR2850 and PR2863. Only generate movddup for 128-bit SSE vector shuffles.
Added:
llvm/trunk/test/CodeGen/X86/2008-10-06-MMXISelBug.ll
Modified:
llvm/trunk/lib/Target/X86/X86ISelLowering.cpp
Modified: llvm/trunk/lib/Target/X86/X86ISelLowering.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86ISelLowering.cpp?rev=57210&r1=57209&r2=57210&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86ISelLowering.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86ISelLowering.cpp Mon Oct 6 16:13:08 2008
@@ -3954,6 +3954,7 @@
// Canonicalize movddup shuffles.
if (V2IsUndef && Subtarget->hasSSE2() &&
+ VT.getSizeInBits() == 128 &&
X86::isMOVDDUPMask(PermMask.getNode()))
return CanonicalizeMovddup(Op, V1, PermMask, DAG, Subtarget->hasSSE3());
Added: llvm/trunk/test/CodeGen/X86/2008-10-06-MMXISelBug.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/2008-10-06-MMXISelBug.ll?rev=57210&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/X86/2008-10-06-MMXISelBug.ll (added)
+++ llvm/trunk/test/CodeGen/X86/2008-10-06-MMXISelBug.ll Mon Oct 6 16:13:08 2008
@@ -0,0 +1,12 @@
+; RUN: llvm-as < %s | llc -march=x86 -mattr=+mmx,+sse2
+; PR2850
+
+ at tmp_V2i = common global <2 x i32> zeroinitializer ; <<2 x i32>*> [#uses=2]
+
+define void @f0() nounwind {
+entry:
+ %0 = load <2 x i32>* @tmp_V2i, align 8 ; <<2 x i32>> [#uses=1]
+ %1 = shufflevector <2 x i32> %0, <2 x i32> undef, <2 x i32> zeroinitializer ; <<2 x i32>> [#uses=1]
+ store <2 x i32> %1, <2 x i32>* @tmp_V2i, align 8
+ ret void
+}
From dpatel at apple.com Mon Oct 6 16:24:49 2008
From: dpatel at apple.com (Devang Patel)
Date: Mon, 06 Oct 2008 21:24:49 -0000
Subject: [llvm-commits] [llvm] r57211 - /llvm/trunk/utils/buildit/build_llvm
Message-ID: <200810062124.m96LOnAW014903@zion.cs.uiuc.edu>
Author: dpatel
Date: Mon Oct 6 16:24:48 2008
New Revision: 57211
URL: http://llvm.org/viewvc/llvm-project?rev=57211&view=rev
Log:
Set UNIVERSAL_ARCH value.
Fixes build failure when target is i386.
Modified:
llvm/trunk/utils/buildit/build_llvm
Modified: llvm/trunk/utils/buildit/build_llvm
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/utils/buildit/build_llvm?rev=57211&r1=57210&r2=57211&view=diff
==============================================================================
--- llvm/trunk/utils/buildit/build_llvm (original)
+++ llvm/trunk/utils/buildit/build_llvm Mon Oct 6 16:24:48 2008
@@ -157,7 +157,8 @@
cd $DIR/obj-llvm || exit 1
# Install the tree into the destination directory.
-make $LOCAL_MAKEFLAGS $OPTIMIZE_OPTS UNIVERSAL=1 OPTIMIZE_OPTION='-O2' install
+make $LOCAL_MAKEFLAGS $OPTIMIZE_OPTS UNIVERSAL=1 UNIVERSAL_ARCH="$TARGETS" \
+ OPTIMIZE_OPTION='-O2' install
if ! test $? == 0 ; then
echo "error: LLVM 'make install' failed!"
From alenhar2 at cs.uiuc.edu Mon Oct 6 17:29:49 2008
From: alenhar2 at cs.uiuc.edu (Andrew Lenharth)
Date: Mon, 06 Oct 2008 22:29:49 -0000
Subject: [llvm-commits] [poolalloc] r57214 -
/poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp
Message-ID: <200810062229.m96MToU0017479@zion.cs.uiuc.edu>
Author: alenhar2
Date: Mon Oct 6 17:29:47 2008
New Revision: 57214
URL: http://llvm.org/viewvc/llvm-project?rev=57214&view=rev
Log:
Preserve calling convention when rewriting a callsite
Modified:
poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp
Modified: poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp?rev=57214&r1=57213&r2=57214&view=diff
==============================================================================
--- poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp (original)
+++ poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp Mon Oct 6 17:29:47 2008
@@ -804,6 +804,8 @@
UpdateNewToOldValueMap(TheCall, NewCall);
}
+ CallSite(NewCall).setCallingConv(CallSite(TheCall).getCallingConv());
+
TheCall->eraseFromParent();
visitInstruction(*NewCall);
}
From dalej at apple.com Mon Oct 6 17:59:10 2008
From: dalej at apple.com (Dale Johannesen)
Date: Mon, 06 Oct 2008 22:59:10 -0000
Subject: [llvm-commits] [llvm] r57218 - in /llvm/trunk:
lib/Support/APFloat.cpp test/CodeGen/X86/2008-10-06-x87ld-nan-1.ll
test/CodeGen/X86/2008-10-06-x87ld-nan-2.ll
Message-ID: <200810062259.m96MxAhe018585@zion.cs.uiuc.edu>
Author: johannes
Date: Mon Oct 6 17:59:10 2008
New Revision: 57218
URL: http://llvm.org/viewvc/llvm-project?rev=57218&view=rev
Log:
Be more precise about which conversions of NaNs
are Inexact. (These are not Inexact as defined
by IEEE754, but that seems like a reasonable way
to abstract what happens: information is lost.)
Added:
llvm/trunk/test/CodeGen/X86/2008-10-06-x87ld-nan-1.ll
llvm/trunk/test/CodeGen/X86/2008-10-06-x87ld-nan-2.ll
Modified:
llvm/trunk/lib/Support/APFloat.cpp
Modified: llvm/trunk/lib/Support/APFloat.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/APFloat.cpp?rev=57218&r1=57217&r2=57218&view=diff
==============================================================================
--- llvm/trunk/lib/Support/APFloat.cpp (original)
+++ llvm/trunk/lib/Support/APFloat.cpp Mon Oct 6 17:59:10 2008
@@ -1721,17 +1721,32 @@
} else if (category == fcNaN) {
int shift = toSemantics.precision - semantics->precision;
// Do this now so significandParts gets the right answer
+ const fltSemantics *oldSemantics = semantics;
semantics = &toSemantics;
+ fs = opOK;
// No normalization here, just truncate
if (shift>0)
APInt::tcShiftLeft(significandParts(), newPartCount, shift);
- else if (shift < 0)
- APInt::tcShiftRight(significandParts(), newPartCount, -shift);
+ else if (shift < 0) {
+ unsigned ushift = -shift;
+ // We mark this as Inexact if we are losing information. This happens
+ // if are shifting out something other than 0s, or if the x87 long
+ // double input did not have its integer bit set (pseudo-NaN), or if the
+ // x87 long double input did not have its QNan bit set (because the x87
+ // hardware sets this bit when converting a lower-precision NaN to
+ // x87 long double).
+ if (APInt::tcLSB(significandParts(), newPartCount) < ushift)
+ fs = opInexact;
+ if (oldSemantics == &APFloat::x87DoubleExtended &&
+ (!(*significandParts() & 0x8000000000000000ULL) ||
+ !(*significandParts() & 0x4000000000000000ULL)))
+ fs = opInexact;
+ APInt::tcShiftRight(significandParts(), newPartCount, ushift);
+ }
// gcc forces the Quiet bit on, which means (float)(double)(float_sNan)
// does not give you back the same bits. This is dubious, and we
// don't currently do it. You're really supposed to get
// an invalid operation signal at runtime, but nobody does that.
- fs = opOK;
} else {
semantics = &toSemantics;
fs = opOK;
Added: llvm/trunk/test/CodeGen/X86/2008-10-06-x87ld-nan-1.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/2008-10-06-x87ld-nan-1.ll?rev=57218&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/X86/2008-10-06-x87ld-nan-1.ll (added)
+++ llvm/trunk/test/CodeGen/X86/2008-10-06-x87ld-nan-1.ll Mon Oct 6 17:59:10 2008
@@ -0,0 +1,13 @@
+; ModuleID = 'nan.bc'
+target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-f80:32:32-v64:64:64-v128:128:128-a0:0:64"
+target triple = "i686-apple-darwin8"
+; RUN: llvm-as < %s | llc -march=x86 -mattr=-sse2,-sse3,-sse | grep fldl
+; This NaN should be shortened to a double (not a float).
+
+declare x86_stdcallcc void @_D3nan5printFeZv(x86_fp80 %f)
+
+define i32 @main() {
+entry_nan.main:
+ call x86_stdcallcc void @_D3nan5printFeZv(x86_fp80 0xK7FFFC001234000000800)
+ ret i32 0
+}
Added: llvm/trunk/test/CodeGen/X86/2008-10-06-x87ld-nan-2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/2008-10-06-x87ld-nan-2.ll?rev=57218&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/X86/2008-10-06-x87ld-nan-2.ll (added)
+++ llvm/trunk/test/CodeGen/X86/2008-10-06-x87ld-nan-2.ll Mon Oct 6 17:59:10 2008
@@ -0,0 +1,18 @@
+; ModuleID = 'nan.bc'
+target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-f80:32:32-v64:64:64-v128:128:128-a0:0:64"
+target triple = "i686-apple-darwin8"
+; RUN: llvm-as < %s | llc -march=x86 -mattr=-sse2,-sse3,-sse | grep fldt | count 3
+; it is not safe to shorten any of these NaNs.
+
+declare x86_stdcallcc void @_D3nan5printFeZv(x86_fp80 %f)
+
+ at _D3nan4rvale = global x86_fp80 0xK7FFF8001234000000000 ; [#uses=1]
+
+define i32 @main() {
+entry_nan.main:
+ %tmp = load x86_fp80* @_D3nan4rvale ; [#uses=1]
+ call x86_stdcallcc void @_D3nan5printFeZv(x86_fp80 %tmp)
+ call x86_stdcallcc void @_D3nan5printFeZv(x86_fp80 0xK7FFF8001234000000000)
+ call x86_stdcallcc void @_D3nan5printFeZv(x86_fp80 0xK7FFFC001234000000400)
+ ret i32 0
+}
From dpatel at apple.com Mon Oct 6 18:22:54 2008
From: dpatel at apple.com (Devang Patel)
Date: Mon, 06 Oct 2008 23:22:54 -0000
Subject: [llvm-commits] [llvm] r57221 - in /llvm/trunk:
lib/Transforms/Scalar/LoopIndexSplit.cpp
test/Transforms/LoopIndexSplit/2008-10-06-Crash.ll
Message-ID: <200810062322.m96NMsxQ019645@zion.cs.uiuc.edu>
Author: dpatel
Date: Mon Oct 6 18:22:54 2008
New Revision: 57221
URL: http://llvm.org/viewvc/llvm-project?rev=57221&view=rev
Log:
Fix typo, fix PR 2865.
Added:
llvm/trunk/test/Transforms/LoopIndexSplit/2008-10-06-Crash.ll
Modified:
llvm/trunk/lib/Transforms/Scalar/LoopIndexSplit.cpp
Modified: llvm/trunk/lib/Transforms/Scalar/LoopIndexSplit.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/LoopIndexSplit.cpp?rev=57221&r1=57220&r2=57221&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/LoopIndexSplit.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/LoopIndexSplit.cpp Mon Oct 6 18:22:54 2008
@@ -940,8 +940,8 @@
if (Op0->getPredicate() == ICmpInst::ICMP_EQ
|| Op0->getPredicate() == ICmpInst::ICMP_NE
- || Op0->getPredicate() == ICmpInst::ICMP_EQ
- || Op0->getPredicate() == ICmpInst::ICMP_NE)
+ || Op1->getPredicate() == ICmpInst::ICMP_EQ
+ || Op1->getPredicate() == ICmpInst::ICMP_NE)
return false;
// Check if SplitCondition dominates entire loop body
Added: llvm/trunk/test/Transforms/LoopIndexSplit/2008-10-06-Crash.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Transforms/LoopIndexSplit/2008-10-06-Crash.ll?rev=57221&view=auto
==============================================================================
--- llvm/trunk/test/Transforms/LoopIndexSplit/2008-10-06-Crash.ll (added)
+++ llvm/trunk/test/Transforms/LoopIndexSplit/2008-10-06-Crash.ll Mon Oct 6 18:22:54 2008
@@ -0,0 +1,31 @@
+; RUN: llvm-as < %s | opt -loop-index-split -disable-output
+ %struct.RExC_state_t = type { i32, i8*, %struct.regexp*, i8*, i8*, i8*, i32, %struct.regnode*, %struct.regnode*, i32, i32, i32, i32, i32, i32, i32, i32, i32 }
+ %struct.SV = type { i8*, i32, i32 }
+ %struct.reg_data = type { i32, i8*, [1 x i8*] }
+ %struct.reg_substr_data = type { [3 x %struct.reg_substr_datum] }
+ %struct.reg_substr_datum = type { i32, i32, %struct.SV*, %struct.SV* }
+ %struct.regexp = type { i32*, i32*, %struct.regnode*, %struct.reg_substr_data*, i8*, %struct.reg_data*, i8*, i32*, i32, i32, i32, i32, i32, i32, i32, i32, [1 x %struct.regnode] }
+ %struct.regnode = type { i8, i8, i16 }
+
+define fastcc %struct.regnode* @S_regclass(%struct.RExC_state_t* %pRExC_state) nounwind {
+entry:
+ br label %bb439
+
+bb439: ; preds = %bb444, %entry
+ %value23.16.reg2mem.0 = phi i32 [ %3, %bb444 ], [ 0, %entry ] ; [#uses=3]
+ %0 = icmp ugt i32 %value23.16.reg2mem.0, 31 ; [#uses=1]
+ %1 = icmp ne i32 %value23.16.reg2mem.0, 127 ; [#uses=1]
+ %2 = and i1 %0, %1 ; [#uses=1]
+ br i1 %2, label %bb443, label %bb444
+
+bb443: ; preds = %bb439
+ br label %bb444
+
+bb444: ; preds = %bb443, %bb439
+ %3 = add i32 %value23.16.reg2mem.0, 1 ; [#uses=2]
+ %4 = icmp ugt i32 %3, 255 ; [#uses=1]
+ br i1 %4, label %bb675, label %bb439
+
+bb675: ; preds = %bb444
+ unreachable
+}
From gohman at apple.com Mon Oct 6 19:12:38 2008
From: gohman at apple.com (Dan Gohman)
Date: Tue, 07 Oct 2008 00:12:38 -0000
Subject: [llvm-commits] [llvm] r57223 -
/llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp
Message-ID: <200810070012.m970CcNs021347@zion.cs.uiuc.edu>
Author: djg
Date: Mon Oct 6 19:12:37 2008
New Revision: 57223
URL: http://llvm.org/viewvc/llvm-project?rev=57223&view=rev
Log:
Correctly handle calls with no return values. This fixes
2006-01-23-UnionInit on x86-64 when inlining is not enabled.
Modified:
llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp?rev=57223&r1=57222&r2=57223&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp Mon Oct 6 19:12:37 2008
@@ -5337,7 +5337,7 @@
Chain = Res.getValue(LoweredRetTys.size() - 1);
// Gather up the call result into a single value.
- if (RetTy != Type::VoidTy) {
+ if (RetTy != Type::VoidTy && !RetTys.empty()) {
ISD::NodeType AssertOp = ISD::DELETED_NODE;
if (RetSExt)
From dalej at apple.com Mon Oct 6 19:40:03 2008
From: dalej at apple.com (Dale Johannesen)
Date: Tue, 07 Oct 2008 00:40:03 -0000
Subject: [llvm-commits] [llvm] r57224 - /llvm/trunk/lib/Support/APFloat.cpp
Message-ID: <200810070040.m970e3G9022211@zion.cs.uiuc.edu>
Author: johannes
Date: Mon Oct 6 19:40:01 2008
New Revision: 57224
URL: http://llvm.org/viewvc/llvm-project?rev=57224&view=rev
Log:
Mark negative-zero-to-int conversion as Inexact,
since -0.0 can't be represented as an int.
This prevents llvm from reducing -0.0 to a
load-and-convert of int 0. Fixes
ieee.exp/mzero[2356].c in gcc testsuite.
Modified:
llvm/trunk/lib/Support/APFloat.cpp
Modified: llvm/trunk/lib/Support/APFloat.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/APFloat.cpp?rev=57224&r1=57223&r2=57224&view=diff
==============================================================================
--- llvm/trunk/lib/Support/APFloat.cpp (original)
+++ llvm/trunk/lib/Support/APFloat.cpp Mon Oct 6 19:40:01 2008
@@ -1784,7 +1784,8 @@
if(category == fcZero) {
APInt::tcSet(parts, 0, dstPartsCount);
- return opOK;
+ // Negative zero can't be represented as an int.
+ return sign ? opInexact : opOK;
}
src = significandParts();
From alenhar2 at cs.uiuc.edu Mon Oct 6 21:10:29 2008
From: alenhar2 at cs.uiuc.edu (Andrew Lenharth)
Date: Tue, 07 Oct 2008 02:10:29 -0000
Subject: [llvm-commits] [llvm] r57226 - in /llvm/trunk:
include/llvm/Intrinsics.td include/llvm/IntrinsicsAlpha.td
lib/Target/Alpha/AlphaISelDAGToDAG.cpp
lib/Target/Alpha/AlphaISelLowering.cpp
Message-ID: <200810070210.m972AUxl026421@zion.cs.uiuc.edu>
Author: alenhar2
Date: Mon Oct 6 21:10:26 2008
New Revision: 57226
URL: http://llvm.org/viewvc/llvm-project?rev=57226&view=rev
Log:
Note that ADDC and company don't actually expand yet (missing in legalize
Added:
llvm/trunk/include/llvm/IntrinsicsAlpha.td
Modified:
llvm/trunk/include/llvm/Intrinsics.td
llvm/trunk/lib/Target/Alpha/AlphaISelDAGToDAG.cpp
llvm/trunk/lib/Target/Alpha/AlphaISelLowering.cpp
Modified: llvm/trunk/include/llvm/Intrinsics.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Intrinsics.td?rev=57226&r1=57225&r2=57226&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Intrinsics.td (original)
+++ llvm/trunk/include/llvm/Intrinsics.td Mon Oct 6 21:10:26 2008
@@ -360,3 +360,4 @@
include "llvm/IntrinsicsX86.td"
include "llvm/IntrinsicsARM.td"
include "llvm/IntrinsicsCellSPU.td"
+include "llvm/IntrinsicsAlpha.td"
Added: llvm/trunk/include/llvm/IntrinsicsAlpha.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/IntrinsicsAlpha.td?rev=57226&view=auto
==============================================================================
--- llvm/trunk/include/llvm/IntrinsicsAlpha.td (added)
+++ llvm/trunk/include/llvm/IntrinsicsAlpha.td Mon Oct 6 21:10:26 2008
@@ -0,0 +1,19 @@
+//===- IntrinsicsAlpha.td - Defines Alpha intrinsics -------*- tablegen -*-===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file defines all of the Alpha-specific intrinsics.
+//
+//===----------------------------------------------------------------------===//
+
+
+let TargetPrefix = "alpha" in { // All intrinsics start with "llvm.alpha.".
+ def int_alpha_umulh : GCCBuiltin<"__builtin_alpha_umulh">,
+ Intrinsic<[llvm_i64_ty, llvm_i64_ty, llvm_i64_ty], [IntrNoMem]>;
+
+}
Modified: llvm/trunk/lib/Target/Alpha/AlphaISelDAGToDAG.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/Alpha/AlphaISelDAGToDAG.cpp?rev=57226&r1=57225&r2=57226&view=diff
==============================================================================
--- llvm/trunk/lib/Target/Alpha/AlphaISelDAGToDAG.cpp (original)
+++ llvm/trunk/lib/Target/Alpha/AlphaISelDAGToDAG.cpp Mon Oct 6 21:10:26 2008
@@ -323,7 +323,8 @@
return CurDAG->SelectNodeTo(N, Alpha::LDQr, MVT::i64, MVT::Other,
CPI, SDValue(Tmp, 0), CurDAG->getEntryNode());
}
- case ISD::TargetConstantFP: {
+ case ISD::TargetConstantFP:
+ case ISD::ConstantFP: {
ConstantFPSDNode *CN = cast(N);
bool isDouble = N->getValueType(0) == MVT::f64;
MVT T = isDouble ? MVT::f64 : MVT::f32;
Modified: llvm/trunk/lib/Target/Alpha/AlphaISelLowering.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/Alpha/AlphaISelLowering.cpp?rev=57226&r1=57225&r2=57226&view=diff
==============================================================================
--- llvm/trunk/lib/Target/Alpha/AlphaISelLowering.cpp (original)
+++ llvm/trunk/lib/Target/Alpha/AlphaISelLowering.cpp Mon Oct 6 21:10:26 2008
@@ -22,6 +22,7 @@
#include "llvm/Constants.h"
#include "llvm/Function.h"
#include "llvm/Module.h"
+#include "llvm/Intrinsics.h"
#include "llvm/Support/CommandLine.h"
using namespace llvm;
@@ -47,7 +48,10 @@
addRegisterClass(MVT::i64, Alpha::GPRCRegisterClass);
addRegisterClass(MVT::f64, Alpha::F8RCRegisterClass);
addRegisterClass(MVT::f32, Alpha::F4RCRegisterClass);
-
+
+ // We want to custom lower some of our intrinsics.
+ setOperationAction(ISD::INTRINSIC_WO_CHAIN, MVT::Other, Custom);
+
setLoadXAction(ISD::EXTLOAD, MVT::i1, Promote);
setLoadXAction(ISD::EXTLOAD, MVT::f32, Expand);
@@ -87,6 +91,12 @@
setOperationAction(ISD::SDIV , MVT::i64, Custom);
setOperationAction(ISD::UDIV , MVT::i64, Custom);
+ setOperationAction(ISD::ADDC , MVT::i64, Expand);
+ setOperationAction(ISD::ADDE , MVT::i64, Expand);
+ setOperationAction(ISD::SUBC , MVT::i64, Expand);
+ setOperationAction(ISD::SUBE , MVT::i64, Expand);
+
+
// We don't support sin/cos/sqrt/pow
setOperationAction(ISD::FSIN , MVT::f64, Expand);
setOperationAction(ISD::FCOS , MVT::f64, Expand);
@@ -311,6 +321,29 @@
DAG.getMachineFunction().getRegInfo().addLiveOut(ArgReg);
break;
}
+ case 5: {
+ MVT ArgVT = Op.getOperand(1).getValueType();
+ unsigned ArgReg1, ArgReg2;
+ if (ArgVT.isInteger()) {
+ ArgReg1 = Alpha::R0;
+ ArgReg2 = Alpha::R1;
+ } else {
+ assert(ArgVT.isFloatingPoint());
+ ArgReg1 = Alpha::F0;
+ ArgReg2 = Alpha::F1;
+ }
+ Copy = DAG.getCopyToReg(Copy, ArgReg1, Op.getOperand(1), Copy.getValue(1));
+ if (std::find(DAG.getMachineFunction().getRegInfo().liveout_begin(),
+ DAG.getMachineFunction().getRegInfo().liveout_end(), ArgReg1)
+ == DAG.getMachineFunction().getRegInfo().liveout_end())
+ DAG.getMachineFunction().getRegInfo().addLiveOut(ArgReg1);
+ Copy = DAG.getCopyToReg(Copy, ArgReg2, Op.getOperand(3), Copy.getValue(1));
+ if (std::find(DAG.getMachineFunction().getRegInfo().liveout_begin(),
+ DAG.getMachineFunction().getRegInfo().liveout_end(), ArgReg2)
+ == DAG.getMachineFunction().getRegInfo().liveout_end())
+ DAG.getMachineFunction().getRegInfo().addLiveOut(ArgReg2);
+ break;
+ }
}
return DAG.getNode(AlphaISD::RET_FLAG, MVT::Other, Copy, Copy.getValue(1));
}
@@ -432,6 +465,15 @@
case ISD::RET: return LowerRET(Op,DAG);
case ISD::JumpTable: return LowerJumpTable(Op, DAG);
+ case ISD::INTRINSIC_WO_CHAIN: {
+ unsigned IntNo = cast(Op.getOperand(0))->getZExtValue();
+ switch (IntNo) {
+ default: break; // Don't custom lower most intrinsics.
+ case Intrinsic::alpha_umulh:
+ return DAG.getNode(ISD::MULHU, MVT::i64, Op.getOperand(1), Op.getOperand(2));
+ }
+ }
+
case ISD::SINT_TO_FP: {
assert(Op.getOperand(0).getValueType() == MVT::i64 &&
"Unhandled SINT_TO_FP type in custom expander!");
From alenhar2 at cs.uiuc.edu Mon Oct 6 21:11:11 2008
From: alenhar2 at cs.uiuc.edu (Andrew Lenharth)
Date: Tue, 07 Oct 2008 02:11:11 -0000
Subject: [llvm-commits] [llvm-gcc-4.2] r57227 - in /llvm-gcc-4.2/trunk/gcc:
config.gcc config/alpha/alpha.h config/alpha/llvm-alpha.cpp
Message-ID: <200810070211.m972BCB7026456@zion.cs.uiuc.edu>
Author: alenhar2
Date: Mon Oct 6 21:11:11 2008
New Revision: 57227
URL: http://llvm.org/viewvc/llvm-project?rev=57227&view=rev
Log:
Get alpha closer to building libgcc2
Added:
llvm-gcc-4.2/trunk/gcc/config/alpha/llvm-alpha.cpp
Modified:
llvm-gcc-4.2/trunk/gcc/config.gcc
llvm-gcc-4.2/trunk/gcc/config/alpha/alpha.h
Modified: llvm-gcc-4.2/trunk/gcc/config.gcc
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/config.gcc?rev=57227&r1=57226&r2=57227&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/config.gcc (original)
+++ llvm-gcc-4.2/trunk/gcc/config.gcc Mon Oct 6 21:11:11 2008
@@ -248,6 +248,9 @@
alpha*-*-*)
cpu_type=alpha
need_64bit_hwint=yes
+# LLVM LOCAL begin
+ out_cxx_file=alpha/llvm-alpha.cpp
+# LLVM LOCAL end
;;
am33_2.0-*-linux*)
cpu_type=mn10300
Modified: llvm-gcc-4.2/trunk/gcc/config/alpha/alpha.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/config/alpha/alpha.h?rev=57227&r1=57226&r2=57227&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/config/alpha/alpha.h (original)
+++ llvm-gcc-4.2/trunk/gcc/config/alpha/alpha.h Mon Oct 6 21:11:11 2008
@@ -1591,3 +1591,22 @@
/* The system headers under Alpha systems are generally C++-aware. */
#define NO_IMPLICIT_EXTERN_C
+
+/* LLVM LOCAL begin */
+#ifdef ENABLE_LLVM
+
+/* LLVM_TARGET_INTRINSIC_PREFIX - Specify what prefix this target uses for its
+ * intrinsics.
+ */
+#define LLVM_TARGET_INTRINSIC_PREFIX "alpha"
+
+/* LLVM_TARGET_INTRINSIC_LOWER - To handle builtins, we want to expand the
+ * invocation into normal LLVM code. If the target can handle the builtin, this
+ * macro should call the target TreeToLLVM::TargetIntrinsicLower method and
+ * return true.This macro is invoked from a method in the TreeToLLVM class.
+ */
+#define LLVM_TARGET_INTRINSIC_LOWER(EXP, BUILTIN_CODE, DESTLOC, RESULT, \
+ DESTTY, OPS) \
+ TargetIntrinsicLower(EXP, BUILTIN_CODE, DESTLOC, RESULT, DESTTY, OPS);
+#endif /* ENABLE_LLVM */
+/* LLVM LOCAL end */
Added: llvm-gcc-4.2/trunk/gcc/config/alpha/llvm-alpha.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/config/alpha/llvm-alpha.cpp?rev=57227&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/config/alpha/llvm-alpha.cpp (added)
+++ llvm-gcc-4.2/trunk/gcc/config/alpha/llvm-alpha.cpp Mon Oct 6 21:11:11 2008
@@ -0,0 +1,121 @@
+/* LLVM LOCAL begin (ENTIRE FILE!) */
+/* High-level LLVM backend interface
+Copyright (C) 2005 Free Software Foundation, Inc.
+Contributed by Evan Cheng (evan.cheng at apple.com)
+
+This file is part of GCC.
+
+GCC is free software; you can redistribute it and/or modify it under
+the terms of the GNU General Public License as published by the Free
+Software Foundation; either version 2, or (at your option) any later
+version.
+
+GCC is distributed in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or
+FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+for more details.
+
+You should have received a copy of the GNU General Public License
+along with GCC; see the file COPYING. If not, write to the Free
+Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+02111-1307, USA. */
+
+//===----------------------------------------------------------------------===//
+// This is a C++ source file that implements specific llvm alpha ABI.
+//===----------------------------------------------------------------------===//
+
+#include "llvm-abi.h"
+#include "llvm-internal.h"
+#include "llvm/DerivedTypes.h"
+#include "llvm/Instructions.h"
+#include "llvm/Intrinsics.h"
+#include "llvm/Module.h"
+
+extern "C" {
+#include "toplev.h"
+}
+
+enum alpha_builtin
+{
+ ALPHA_BUILTIN_CMPBGE,
+ ALPHA_BUILTIN_EXTBL,
+ ALPHA_BUILTIN_EXTWL,
+ ALPHA_BUILTIN_EXTLL,
+ ALPHA_BUILTIN_EXTQL,
+ ALPHA_BUILTIN_EXTWH,
+ ALPHA_BUILTIN_EXTLH,
+ ALPHA_BUILTIN_EXTQH,
+ ALPHA_BUILTIN_INSBL,
+ ALPHA_BUILTIN_INSWL,
+ ALPHA_BUILTIN_INSLL,
+ ALPHA_BUILTIN_INSQL,
+ ALPHA_BUILTIN_INSWH,
+ ALPHA_BUILTIN_INSLH,
+ ALPHA_BUILTIN_INSQH,
+ ALPHA_BUILTIN_MSKBL,
+ ALPHA_BUILTIN_MSKWL,
+ ALPHA_BUILTIN_MSKLL,
+ ALPHA_BUILTIN_MSKQL,
+ ALPHA_BUILTIN_MSKWH,
+ ALPHA_BUILTIN_MSKLH,
+ ALPHA_BUILTIN_MSKQH,
+ ALPHA_BUILTIN_UMULH,
+ ALPHA_BUILTIN_ZAP,
+ ALPHA_BUILTIN_ZAPNOT,
+ ALPHA_BUILTIN_AMASK,
+ ALPHA_BUILTIN_IMPLVER,
+ ALPHA_BUILTIN_RPCC,
+ ALPHA_BUILTIN_THREAD_POINTER,
+ ALPHA_BUILTIN_SET_THREAD_POINTER,
+
+ /* TARGET_MAX */
+ ALPHA_BUILTIN_MINUB8,
+ ALPHA_BUILTIN_MINSB8,
+ ALPHA_BUILTIN_MINUW4,
+ ALPHA_BUILTIN_MINSW4,
+ ALPHA_BUILTIN_MAXUB8,
+ ALPHA_BUILTIN_MAXSB8,
+ ALPHA_BUILTIN_MAXUW4,
+ ALPHA_BUILTIN_MAXSW4,
+ ALPHA_BUILTIN_PERR,
+ ALPHA_BUILTIN_PKLB,
+ ALPHA_BUILTIN_PKWB,
+ ALPHA_BUILTIN_UNPKBL,
+ ALPHA_BUILTIN_UNPKBW,
+
+ /* TARGET_CIX */
+ ALPHA_BUILTIN_CTTZ,
+ ALPHA_BUILTIN_CTLZ,
+ ALPHA_BUILTIN_CTPOP,
+
+ ALPHA_BUILTIN_max
+};
+
+/* TargetIntrinsicLower - For builtins that we want to expand to normal LLVM
+ * code, emit the code now. If we can handle the code, this macro should emit
+ * the code, return true.
+ */
+bool TreeToLLVM::TargetIntrinsicLower(tree exp,
+ unsigned FnCode,
+ const MemRef *DestLoc,
+ Value *&Result,
+ const Type *ResultType,
+ std::vector &Ops) {
+ switch (FnCode) {
+ case ALPHA_BUILTIN_UMULH: {
+ Function *f =
+ Intrinsic::getDeclaration(TheModule, Intrinsic::alpha_umulh);
+ Value *Arg0 = Ops[0];
+ Value *Arg1 = Ops[1];
+ Value *CallOps[2] = { Arg0, Arg1};
+ Result = Builder.CreateCall(f, CallOps, CallOps+2, "tmp");
+ Result = Builder.CreateBitCast(Result, ResultType, "tmp");
+ return true;
+ }
+ default: break;
+ }
+
+ return false;
+}
+
+/* LLVM LOCAL end (ENTIRE FILE!) */
From alenhar2 at cs.uiuc.edu Mon Oct 6 21:30:14 2008
From: alenhar2 at cs.uiuc.edu (Andrew Lenharth)
Date: Tue, 07 Oct 2008 02:30:14 -0000
Subject: [llvm-commits] [llvm] r57228 -
/llvm/trunk/test/CodeGen/Alpha/add128.ll
Message-ID: <200810070230.m972UEpV026995@zion.cs.uiuc.edu>
Author: alenhar2
Date: Mon Oct 6 21:30:13 2008
New Revision: 57228
URL: http://llvm.org/viewvc/llvm-project?rev=57228&view=rev
Log:
Add test case for ADDC ADDE expansion
Added:
llvm/trunk/test/CodeGen/Alpha/add128.ll
Added: llvm/trunk/test/CodeGen/Alpha/add128.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Alpha/add128.ll?rev=57228&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/Alpha/add128.ll (added)
+++ llvm/trunk/test/CodeGen/Alpha/add128.ll Mon Oct 6 21:30:13 2008
@@ -0,0 +1,10 @@
+;test for ADDC and ADDE expansion
+;
+; RUN: llvm-as < %s | llc -march=alpha -o %t.s -f
+; XFAIL: *
+
+define i128 @add128(i128 %x, i128 %y) {
+entry:
+ %tmp = add i128 %y, %x
+ ret i128 %tmp
+}
From clattner at apple.com Mon Oct 6 23:04:17 2008
From: clattner at apple.com (Chris Lattner)
Date: Mon, 6 Oct 2008 21:04:17 -0700
Subject: [llvm-commits] [llvm] r57226 - in /llvm/trunk:
include/llvm/Intrinsics.td include/llvm/IntrinsicsAlpha.td
lib/Target/Alpha/AlphaISelDAGToDAG.cpp
lib/Target/Alpha/AlphaISelLowering.cpp
In-Reply-To: <200810070210.m972AUxl026421@zion.cs.uiuc.edu>
References: <200810070210.m972AUxl026421@zion.cs.uiuc.edu>
Message-ID: <1589FB2C-9155-4943-9BEB-B775B11DFCB8@apple.com>
On Oct 6, 2008, at 7:10 PM, Andrew Lenharth wrote:
> Author: alenhar2
> Date: Mon Oct 6 21:10:26 2008
> New Revision: 57226
>
> URL: http://llvm.org/viewvc/llvm-project?rev=57226&view=rev
> Log:
> Note that ADDC and company don't actually expand yet (missing in
> legalize
Hi Andrew,
__builtin_alpha_umulh can be represented with generic LLVM IR (zext to
i128, multiply, shr by 64, truncate to i64). You should get good code
for that sequence already, if not, that's a bug.
Can you just have llvm-gcc expand the builtin like we do for other
builtins supported by LLVM IR?
-Chris
From clattner at apple.com Mon Oct 6 23:05:37 2008
From: clattner at apple.com (Chris Lattner)
Date: Mon, 6 Oct 2008 21:05:37 -0700
Subject: [llvm-commits] [llvm-gcc-4.2] r57227 - in
/llvm-gcc-4.2/trunk/gcc: config.gcc config/alpha/alpha.h
config/alpha/llvm-alpha.cpp
In-Reply-To: <200810070211.m972BCB7026456@zion.cs.uiuc.edu>
References: <200810070211.m972BCB7026456@zion.cs.uiuc.edu>
Message-ID: <818DB8E0-A0D9-4F07-9EE6-EF85EB2E9EBE@apple.com>
On Oct 6, 2008, at 7:11 PM, Andrew Lenharth wrote:
> Author: alenhar2
> Date: Mon Oct 6 21:11:11 2008
> New Revision: 57227
>
> URL: http://llvm.org/viewvc/llvm-project?rev=57227&view=rev
> Log:
> Get alpha closer to building libgcc2
Ok
+bool TreeToLLVM::TargetIntrinsicLower(tree exp,
> + unsigned FnCode,
> + const MemRef *DestLoc,
> + Value *&Result,
> + const Type *ResultType,
> + std::vector &Ops) {
If you make an llvm intrinsic that maps 1-1 with a GCC builtin, you
generally don't have to do lowering like this.
This would be a great place to lower it to llvm ir though :)
-Chris
>
> + switch (FnCode) {
> + case ALPHA_BUILTIN_UMULH: {
> + Function *f =
> + Intrinsic::getDeclaration(TheModule, Intrinsic::alpha_umulh);
> + Value *Arg0 = Ops[0];
> + Value *Arg1 = Ops[1];
> + Value *CallOps[2] = { Arg0, Arg1};
> + Result = Builder.CreateCall(f, CallOps, CallOps+2, "tmp");
> + Result = Builder.CreateBitCast(Result, ResultType, "tmp");
> + return true;
> + }
> + default: break;
> + }
> +
> + return false;
> +}
> +
> +/* LLVM LOCAL end (ENTIRE FILE!) */
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From tonic at nondot.org Mon Oct 6 23:06:02 2008
From: tonic at nondot.org (Tanya Lattner)
Date: Tue, 07 Oct 2008 04:06:02 -0000
Subject: [llvm-commits] [llvm] r57229 - /llvm/branches/release_24/
Message-ID: <200810070406.m97463Q7030040@zion.cs.uiuc.edu>
Author: tbrethou
Date: Mon Oct 6 23:06:01 2008
New Revision: 57229
URL: http://llvm.org/viewvc/llvm-project?rev=57229&view=rev
Log:
Create 2.4 release branch.
Added:
llvm/branches/release_24/
- copied from r57228, llvm/trunk/
From tonic at nondot.org Mon Oct 6 23:06:26 2008
From: tonic at nondot.org (Tanya Lattner)
Date: Tue, 07 Oct 2008 04:06:26 -0000
Subject: [llvm-commits] [llvm-gcc-4.2] r57230 -
/llvm-gcc-4.2/branches/release_24/
Message-ID: <200810070406.m9746QcV030065@zion.cs.uiuc.edu>
Author: tbrethou
Date: Mon Oct 6 23:06:26 2008
New Revision: 57230
URL: http://llvm.org/viewvc/llvm-project?rev=57230&view=rev
Log:
Create 2.4 release branch.
Added:
llvm-gcc-4.2/branches/release_24/
- copied from r57229, llvm-gcc-4.2/trunk/
From tonic at nondot.org Mon Oct 6 23:06:50 2008
From: tonic at nondot.org (Tanya Lattner)
Date: Tue, 07 Oct 2008 04:06:50 -0000
Subject: [llvm-commits] [test-suite] r57231 -
/test-suite/branches/release_24/
Message-ID: <200810070406.m9746oIj030085@zion.cs.uiuc.edu>
Author: tbrethou
Date: Mon Oct 6 23:06:50 2008
New Revision: 57231
URL: http://llvm.org/viewvc/llvm-project?rev=57231&view=rev
Log:
Create 2.4 release branch.
Added:
test-suite/branches/release_24/
- copied from r57230, test-suite/trunk/
From sabre at nondot.org Mon Oct 6 23:06:55 2008
From: sabre at nondot.org (Chris Lattner)
Date: Tue, 07 Oct 2008 04:06:55 -0000
Subject: [llvm-commits] [llvm] r57232 -
/llvm/trunk/test/CodeGen/Alpha/add128.ll
Message-ID: <200810070406.m9746tIB030100@zion.cs.uiuc.edu>
Author: lattner
Date: Mon Oct 6 23:06:55 2008
New Revision: 57232
URL: http://llvm.org/viewvc/llvm-project?rev=57232&view=rev
Log:
no need to write the output to the disk
Modified:
llvm/trunk/test/CodeGen/Alpha/add128.ll
Modified: llvm/trunk/test/CodeGen/Alpha/add128.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Alpha/add128.ll?rev=57232&r1=57231&r2=57232&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/Alpha/add128.ll (original)
+++ llvm/trunk/test/CodeGen/Alpha/add128.ll Mon Oct 6 23:06:55 2008
@@ -1,6 +1,6 @@
;test for ADDC and ADDE expansion
;
-; RUN: llvm-as < %s | llc -march=alpha -o %t.s -f
+; RUN: llvm-as < %s | llc -march=alpha
; XFAIL: *
define i128 @add128(i128 %x, i128 %y) {
From tonic at nondot.org Mon Oct 6 23:35:09 2008
From: tonic at nondot.org (Tanya Lattner)
Date: Tue, 07 Oct 2008 04:35:09 -0000
Subject: [llvm-commits] [llvm] r57233 - in /llvm/trunk:
autoconf/configure.ac configure
Message-ID: <200810070435.m974ZAwd031588@zion.cs.uiuc.edu>
Author: tbrethou
Date: Mon Oct 6 23:35:08 2008
New Revision: 57233
URL: http://llvm.org/viewvc/llvm-project?rev=57233&view=rev
Log:
Advance version to 2.5
Modified:
llvm/trunk/autoconf/configure.ac
llvm/trunk/configure
Modified: llvm/trunk/autoconf/configure.ac
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/autoconf/configure.ac?rev=57233&r1=57232&r2=57233&view=diff
==============================================================================
--- llvm/trunk/autoconf/configure.ac (original)
+++ llvm/trunk/autoconf/configure.ac Mon Oct 6 23:35:08 2008
@@ -31,7 +31,7 @@
dnl===-----------------------------------------------------------------------===
dnl Initialize autoconf and define the package name, version number and
dnl email address for reporting bugs.
-AC_INIT([[llvm]],[[2.4svn]],[llvmbugs at cs.uiuc.edu])
+AC_INIT([[llvm]],[[2.5svn]],[llvmbugs at cs.uiuc.edu])
dnl Provide a copyright substitution and ensure the copyright notice is included
dnl in the output of --version option of the generated configure script.
Modified: llvm/trunk/configure
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/configure?rev=57233&r1=57232&r2=57233&view=diff
==============================================================================
--- llvm/trunk/configure (original)
+++ llvm/trunk/configure Mon Oct 6 23:35:08 2008
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.60 for llvm 2.4svn.
+# Generated by GNU Autoconf 2.60 for llvm 2.5svn.
#
# Report bugs to .
#
@@ -715,8 +715,8 @@
# Identity of this package.
PACKAGE_NAME='llvm'
PACKAGE_TARNAME='-llvm-'
-PACKAGE_VERSION='2.4svn'
-PACKAGE_STRING='llvm 2.4svn'
+PACKAGE_VERSION='2.5svn'
+PACKAGE_STRING='llvm 2.5svn'
PACKAGE_BUGREPORT='llvmbugs at cs.uiuc.edu'
ac_unique_file="lib/VMCore/Module.cpp"
@@ -1462,7 +1462,7 @@
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures llvm 2.4svn to adapt to many kinds of systems.
+\`configure' configures llvm 2.5svn to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1528,7 +1528,7 @@
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of llvm 2.4svn:";;
+ short | recursive ) echo "Configuration of llvm 2.5svn:";;
esac
cat <<\_ACEOF
@@ -1663,7 +1663,7 @@
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-llvm configure 2.4svn
+llvm configure 2.5svn
generated by GNU Autoconf 2.60
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1679,7 +1679,7 @@
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by llvm $as_me 2.4svn, which was
+It was created by llvm $as_me 2.5svn, which was
generated by GNU Autoconf 2.60. Invocation command line was
$ $0 $@
@@ -9002,7 +9002,9 @@
fi
- if test x"${enable_ltdl_install-no}" != xno; then
+
+
+if test x"${enable_ltdl_install-no}" != xno; then
INSTALL_LTDL_TRUE=
INSTALL_LTDL_FALSE='#'
else
@@ -9010,7 +9012,9 @@
INSTALL_LTDL_FALSE=
fi
- if test x"${enable_ltdl_convenience-no}" != xno; then
+
+
+if test x"${enable_ltdl_convenience-no}" != xno; then
CONVENIENCE_LTDL_TRUE=
CONVENIENCE_LTDL_FALSE='#'
else
@@ -10777,7 +10781,7 @@
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext < conftest.$ac_ext
+ echo '#line 12928 "configure"' > conftest.$ac_ext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
@@ -14639,11 +14643,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:14642: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:14646: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:14646: \$? = $ac_status" >&5
+ echo "$as_me:14650: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -14907,11 +14911,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:14910: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:14914: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:14914: \$? = $ac_status" >&5
+ echo "$as_me:14918: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -15011,11 +15015,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:15014: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:15018: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:15018: \$? = $ac_status" >&5
+ echo "$as_me:15022: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -17463,7 +17467,7 @@
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext < conftest.$ac_ext <&5)
+ (eval echo "\"\$as_me:19938: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:19938: \$? = $ac_status" >&5
+ echo "$as_me:19942: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -20035,11 +20039,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:20038: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:20042: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:20042: \$? = $ac_status" >&5
+ echo "$as_me:20046: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -21605,11 +21609,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:21608: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:21612: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:21612: \$? = $ac_status" >&5
+ echo "$as_me:21616: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -21709,11 +21713,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:21712: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:21716: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:21716: \$? = $ac_status" >&5
+ echo "$as_me:21720: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -23944,11 +23948,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:23947: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:23951: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:23951: \$? = $ac_status" >&5
+ echo "$as_me:23955: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -24212,11 +24216,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:24215: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:24219: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:24219: \$? = $ac_status" >&5
+ echo "$as_me:24223: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -24316,11 +24320,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:24319: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:24323: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:24323: \$? = $ac_status" >&5
+ echo "$as_me:24327: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -34242,7 +34246,7 @@
LLVMGCC_MAJVERS=$llvmgccmajvers
- llvmgcclangs=`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ ]*\).*/\1/'`
+ llvmgcclangs=`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ -]*\).*/\1/'`
LLVMGCC_LANGS=$llvmgcclangs
{ echo "$as_me:$LINENO: result: ok" >&5
@@ -34947,7 +34951,7 @@
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by llvm $as_me 2.4svn, which was
+This file was extended by llvm $as_me 2.5svn, which was
generated by GNU Autoconf 2.60. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -35000,7 +35004,7 @@
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
ac_cs_version="\\
-llvm config.status 2.4svn
+llvm config.status 2.5svn
configured by $0, generated by GNU Autoconf 2.60,
with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
From lattner at apple.com Mon Oct 6 23:35:38 2008
From: lattner at apple.com (Tanya Lattner)
Date: Mon, 6 Oct 2008 21:35:38 -0700
Subject: [llvm-commits] [llvm] r57167 - in /llvm/trunk: configure
test/FrontendObjC++/dg.exp test/lib/llvm.exp
In-Reply-To: <200810061031.m96AVU4e024330@zion.cs.uiuc.edu>
References: <200810061031.m96AVU4e024330@zion.cs.uiuc.edu>
Message-ID: <2A7F209F-0677-40E9-AFF4-EADE5D94AB44@apple.com>
Duncan,
Did you forget to check in autoconf/configure.ac?
This is going to be reverted with my checkin of the new configure
script. It is also not going to the release. Please send me a patch.
Thanks,
Tanya
On Oct 6, 2008, at 3:31 AM, Duncan Sands wrote:
> Author: baldrick
> Date: Mon Oct 6 05:31:21 2008
> New Revision: 57167
>
> URL: http://llvm.org/viewvc/llvm-project?rev=57167&view=rev
> Log:
> Actually run Obj-C++ tests if llvm-gcc supports.
> Before there were two problems: (1) configure
> turned "obj-c++" into "obj" in the langs line;
> (2) the dejagnu library called it objc++ not
> obj-c++.
> Now the problem is that some of these tests don't
> pass!
>
> Modified:
> llvm/trunk/configure
> llvm/trunk/test/FrontendObjC++/dg.exp
> llvm/trunk/test/lib/llvm.exp
>
> Modified: llvm/trunk/configure
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/configure?rev=57167&r1=57166&r2=57167&view=diff
>
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- llvm/trunk/configure (original)
> +++ llvm/trunk/configure Mon Oct 6 05:31:21 2008
> @@ -34242,7 +34242,7 @@
>
> LLVMGCC_MAJVERS=$llvmgccmajvers
>
> - llvmgcclangs=`"$LLVMGCC" -v --help 2>&1 | grep '^Configured
> with:' | sed 's/^.*--enable-languages=\([^ -]*\).*/\1/'`
> + llvmgcclangs=`"$LLVMGCC" -v --help 2>&1 | grep '^Configured
> with:' | sed 's/^.*--enable-languages=\([^ ]*\).*/\1/'`
> LLVMGCC_LANGS=$llvmgcclangs
>
> { echo "$as_me:$LINENO: result: ok" >&5
>
> Modified: llvm/trunk/test/FrontendObjC++/dg.exp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/FrontendObjC%2B%2B/dg.exp?rev=57167&r1=57166&r2=57167&view=diff
>
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- llvm/trunk/test/FrontendObjC++/dg.exp (original)
> +++ llvm/trunk/test/FrontendObjC++/dg.exp Mon Oct 6 05:31:21 2008
> @@ -1,5 +1,5 @@
> load_lib llvm.exp
>
> -if [ llvm_gcc_supports objc++ ] then {
> +if [ llvm_gcc_supports obj-c++ ] then {
> RunLLVMTests [lsort [glob -nocomplain $srcdir/$subdir/*.{mm}]]
> }
>
> Modified: llvm/trunk/test/lib/llvm.exp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/lib/llvm.exp?rev=57167&r1=57166&r2=57167&view=diff
>
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- llvm/trunk/test/lib/llvm.exp (original)
> +++ llvm/trunk/test/lib/llvm.exp Mon Oct 6 05:31:21 2008
> @@ -237,7 +237,7 @@
> c { set file cc1 }
> c++ { set file cc1plus }
> objc { set file cc1obj }
> - objc++ { set file cc1objplus }
> + obj-c++ { set file cc1objplus }
> fortran { set file f951 }
> default { return 0 }
> }
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From tonic at nondot.org Mon Oct 6 23:41:14 2008
From: tonic at nondot.org (Tanya Lattner)
Date: Tue, 07 Oct 2008 04:41:14 -0000
Subject: [llvm-commits] [test-suite] r57234 - in /test-suite/trunk:
autoconf/configure.ac configure
Message-ID: <200810070441.m974fELQ031977@zion.cs.uiuc.edu>
Author: tbrethou
Date: Mon Oct 6 23:41:14 2008
New Revision: 57234
URL: http://llvm.org/viewvc/llvm-project?rev=57234&view=rev
Log:
Advance to 2.5
Modified:
test-suite/trunk/autoconf/configure.ac
test-suite/trunk/configure
Modified: test-suite/trunk/autoconf/configure.ac
URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/autoconf/configure.ac?rev=57234&r1=57233&r2=57234&view=diff
==============================================================================
--- test-suite/trunk/autoconf/configure.ac (original)
+++ test-suite/trunk/autoconf/configure.ac Mon Oct 6 23:41:14 2008
@@ -1,5 +1,5 @@
dnl Initialize autoconf
-AC_INIT([[LLVM-TEST]],[[2.4svn]],[llvmbugs at cs.uiuc.edu])
+AC_INIT([[LLVM-TEST]],[[2.5svn]],[llvmbugs at cs.uiuc.edu])
dnl Place all of the extra autoconf files into the config subdirectory
AC_CONFIG_AUX_DIR([autoconf])
Modified: test-suite/trunk/configure
URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/configure?rev=57234&r1=57233&r2=57234&view=diff
==============================================================================
--- test-suite/trunk/configure (original)
+++ test-suite/trunk/configure Mon Oct 6 23:41:14 2008
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.60 for LLVM-TEST 2.4svn.
+# Generated by GNU Autoconf 2.60 for LLVM-TEST 2.5svn.
#
# Report bugs to .
#
@@ -713,8 +713,8 @@
# Identity of this package.
PACKAGE_NAME='LLVM-TEST'
PACKAGE_TARNAME='-llvm-test-'
-PACKAGE_VERSION='2.4svn'
-PACKAGE_STRING='LLVM-TEST 2.4svn'
+PACKAGE_VERSION='2.5svn'
+PACKAGE_STRING='LLVM-TEST 2.5svn'
PACKAGE_BUGREPORT='llvmbugs at cs.uiuc.edu'
ac_unique_file="SingleSource/Benchmarks/Makefile"
@@ -1389,7 +1389,7 @@
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures LLVM-TEST 2.4svn to adapt to many kinds of systems.
+\`configure' configures LLVM-TEST 2.5svn to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1454,7 +1454,7 @@
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of LLVM-TEST 2.4svn:";;
+ short | recursive ) echo "Configuration of LLVM-TEST 2.5svn:";;
esac
cat <<\_ACEOF
@@ -1576,7 +1576,7 @@
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-LLVM-TEST configure 2.4svn
+LLVM-TEST configure 2.5svn
generated by GNU Autoconf 2.60
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1590,7 +1590,7 @@
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by LLVM-TEST $as_me 2.4svn, which was
+It was created by LLVM-TEST $as_me 2.5svn, which was
generated by GNU Autoconf 2.60. Invocation command line was
$ $0 $@
@@ -21257,7 +21257,7 @@
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by LLVM-TEST $as_me 2.4svn, which was
+This file was extended by LLVM-TEST $as_me 2.5svn, which was
generated by GNU Autoconf 2.60. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -21304,7 +21304,7 @@
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
ac_cs_version="\\
-LLVM-TEST config.status 2.4svn
+LLVM-TEST config.status 2.5svn
configured by $0, generated by GNU Autoconf 2.60,
with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
From tonic at nondot.org Mon Oct 6 23:43:29 2008
From: tonic at nondot.org (Tanya Lattner)
Date: Tue, 07 Oct 2008 04:43:29 -0000
Subject: [llvm-commits] [llvm] r57235 - in /llvm/branches/release_24:
autoconf/configure.ac configure
Message-ID: <200810070443.m974hTFX032300@zion.cs.uiuc.edu>
Author: tbrethou
Date: Mon Oct 6 23:43:28 2008
New Revision: 57235
URL: http://llvm.org/viewvc/llvm-project?rev=57235&view=rev
Log:
Correct version number.
Modified:
llvm/branches/release_24/autoconf/configure.ac
llvm/branches/release_24/configure
Modified: llvm/branches/release_24/autoconf/configure.ac
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_24/autoconf/configure.ac?rev=57235&r1=57234&r2=57235&view=diff
==============================================================================
--- llvm/branches/release_24/autoconf/configure.ac (original)
+++ llvm/branches/release_24/autoconf/configure.ac Mon Oct 6 23:43:28 2008
@@ -31,7 +31,7 @@
dnl===-----------------------------------------------------------------------===
dnl Initialize autoconf and define the package name, version number and
dnl email address for reporting bugs.
-AC_INIT([[llvm]],[[2.4svn]],[llvmbugs at cs.uiuc.edu])
+AC_INIT([[llvm]],[[2.4]],[llvmbugs at cs.uiuc.edu])
dnl Provide a copyright substitution and ensure the copyright notice is included
dnl in the output of --version option of the generated configure script.
Modified: llvm/branches/release_24/configure
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_24/configure?rev=57235&r1=57234&r2=57235&view=diff
==============================================================================
--- llvm/branches/release_24/configure (original)
+++ llvm/branches/release_24/configure Mon Oct 6 23:43:28 2008
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.60 for llvm 2.4svn.
+# Generated by GNU Autoconf 2.60 for llvm 2.4.
#
# Report bugs to .
#
@@ -715,8 +715,8 @@
# Identity of this package.
PACKAGE_NAME='llvm'
PACKAGE_TARNAME='-llvm-'
-PACKAGE_VERSION='2.4svn'
-PACKAGE_STRING='llvm 2.4svn'
+PACKAGE_VERSION='2.4'
+PACKAGE_STRING='llvm 2.4'
PACKAGE_BUGREPORT='llvmbugs at cs.uiuc.edu'
ac_unique_file="lib/VMCore/Module.cpp"
@@ -1462,7 +1462,7 @@
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures llvm 2.4svn to adapt to many kinds of systems.
+\`configure' configures llvm 2.4 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1528,7 +1528,7 @@
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of llvm 2.4svn:";;
+ short | recursive ) echo "Configuration of llvm 2.4:";;
esac
cat <<\_ACEOF
@@ -1663,7 +1663,7 @@
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-llvm configure 2.4svn
+llvm configure 2.4
generated by GNU Autoconf 2.60
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1679,7 +1679,7 @@
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by llvm $as_me 2.4svn, which was
+It was created by llvm $as_me 2.4, which was
generated by GNU Autoconf 2.60. Invocation command line was
$ $0 $@
@@ -9002,7 +9002,9 @@
fi
- if test x"${enable_ltdl_install-no}" != xno; then
+
+
+if test x"${enable_ltdl_install-no}" != xno; then
INSTALL_LTDL_TRUE=
INSTALL_LTDL_FALSE='#'
else
@@ -9010,7 +9012,9 @@
INSTALL_LTDL_FALSE=
fi
- if test x"${enable_ltdl_convenience-no}" != xno; then
+
+
+if test x"${enable_ltdl_convenience-no}" != xno; then
CONVENIENCE_LTDL_TRUE=
CONVENIENCE_LTDL_FALSE='#'
else
@@ -10777,7 +10781,7 @@
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext < conftest.$ac_ext
+ echo '#line 12928 "configure"' > conftest.$ac_ext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
@@ -14639,11 +14643,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:14642: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:14646: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:14646: \$? = $ac_status" >&5
+ echo "$as_me:14650: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -14907,11 +14911,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:14910: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:14914: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:14914: \$? = $ac_status" >&5
+ echo "$as_me:14918: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -15011,11 +15015,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:15014: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:15018: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:15018: \$? = $ac_status" >&5
+ echo "$as_me:15022: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -17463,7 +17467,7 @@
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext < conftest.$ac_ext <&5)
+ (eval echo "\"\$as_me:19938: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:19938: \$? = $ac_status" >&5
+ echo "$as_me:19942: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -20035,11 +20039,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:20038: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:20042: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:20042: \$? = $ac_status" >&5
+ echo "$as_me:20046: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -21605,11 +21609,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:21608: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:21612: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:21612: \$? = $ac_status" >&5
+ echo "$as_me:21616: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -21709,11 +21713,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:21712: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:21716: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:21716: \$? = $ac_status" >&5
+ echo "$as_me:21720: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -23944,11 +23948,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:23947: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:23951: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:23951: \$? = $ac_status" >&5
+ echo "$as_me:23955: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -24212,11 +24216,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:24215: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:24219: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:24219: \$? = $ac_status" >&5
+ echo "$as_me:24223: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -24316,11 +24320,11 @@
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:24319: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:24323: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:24323: \$? = $ac_status" >&5
+ echo "$as_me:24327: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -34242,7 +34246,7 @@
LLVMGCC_MAJVERS=$llvmgccmajvers
- llvmgcclangs=`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ ]*\).*/\1/'`
+ llvmgcclangs=`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ -]*\).*/\1/'`
LLVMGCC_LANGS=$llvmgcclangs
{ echo "$as_me:$LINENO: result: ok" >&5
@@ -34947,7 +34951,7 @@
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by llvm $as_me 2.4svn, which was
+This file was extended by llvm $as_me 2.4, which was
generated by GNU Autoconf 2.60. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -35000,7 +35004,7 @@
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
ac_cs_version="\\
-llvm config.status 2.4svn
+llvm config.status 2.4
configured by $0, generated by GNU Autoconf 2.60,
with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
From tonic at nondot.org Mon Oct 6 23:48:30 2008
From: tonic at nondot.org (Tanya Lattner)
Date: Tue, 07 Oct 2008 04:48:30 -0000
Subject: [llvm-commits] [test-suite] r57236 - in
/test-suite/branches/release_24: autoconf/configure.ac configure
Message-ID: <200810070448.m974mUDr000368@zion.cs.uiuc.edu>
Author: tbrethou
Date: Mon Oct 6 23:48:29 2008
New Revision: 57236
URL: http://llvm.org/viewvc/llvm-project?rev=57236&view=rev
Log:
Set version number to 2.4
Modified:
test-suite/branches/release_24/autoconf/configure.ac
test-suite/branches/release_24/configure
Modified: test-suite/branches/release_24/autoconf/configure.ac
URL: http://llvm.org/viewvc/llvm-project/test-suite/branches/release_24/autoconf/configure.ac?rev=57236&r1=57235&r2=57236&view=diff
==============================================================================
--- test-suite/branches/release_24/autoconf/configure.ac (original)
+++ test-suite/branches/release_24/autoconf/configure.ac Mon Oct 6 23:48:29 2008
@@ -1,5 +1,5 @@
dnl Initialize autoconf
-AC_INIT([[LLVM-TEST]],[[2.4svn]],[llvmbugs at cs.uiuc.edu])
+AC_INIT([[LLVM-TEST]],[[2.4]],[llvmbugs at cs.uiuc.edu])
dnl Place all of the extra autoconf files into the config subdirectory
AC_CONFIG_AUX_DIR([autoconf])
Modified: test-suite/branches/release_24/configure
URL: http://llvm.org/viewvc/llvm-project/test-suite/branches/release_24/configure?rev=57236&r1=57235&r2=57236&view=diff
==============================================================================
--- test-suite/branches/release_24/configure (original)
+++ test-suite/branches/release_24/configure Mon Oct 6 23:48:29 2008
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.60 for LLVM-TEST 2.4svn.
+# Generated by GNU Autoconf 2.60 for LLVM-TEST 2.4.
#
# Report bugs to .
#
@@ -713,8 +713,8 @@
# Identity of this package.
PACKAGE_NAME='LLVM-TEST'
PACKAGE_TARNAME='-llvm-test-'
-PACKAGE_VERSION='2.4svn'
-PACKAGE_STRING='LLVM-TEST 2.4svn'
+PACKAGE_VERSION='2.4'
+PACKAGE_STRING='LLVM-TEST 2.4'
PACKAGE_BUGREPORT='llvmbugs at cs.uiuc.edu'
ac_unique_file="SingleSource/Benchmarks/Makefile"
@@ -1389,7 +1389,7 @@
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures LLVM-TEST 2.4svn to adapt to many kinds of systems.
+\`configure' configures LLVM-TEST 2.4 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1454,7 +1454,7 @@
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of LLVM-TEST 2.4svn:";;
+ short | recursive ) echo "Configuration of LLVM-TEST 2.4:";;
esac
cat <<\_ACEOF
@@ -1576,7 +1576,7 @@
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-LLVM-TEST configure 2.4svn
+LLVM-TEST configure 2.4
generated by GNU Autoconf 2.60
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1590,7 +1590,7 @@
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by LLVM-TEST $as_me 2.4svn, which was
+It was created by LLVM-TEST $as_me 2.4, which was
generated by GNU Autoconf 2.60. Invocation command line was
$ $0 $@
@@ -21257,7 +21257,7 @@
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by LLVM-TEST $as_me 2.4svn, which was
+This file was extended by LLVM-TEST $as_me 2.4, which was
generated by GNU Autoconf 2.60. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -21304,7 +21304,7 @@
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
ac_cs_version="\\
-LLVM-TEST config.status 2.4svn
+LLVM-TEST config.status 2.4
configured by $0, generated by GNU Autoconf 2.60,
with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
From nicholas at mxc.ca Tue Oct 7 00:22:27 2008
From: nicholas at mxc.ca (Nick Lewycky)
Date: Mon, 06 Oct 2008 22:22:27 -0700
Subject: [llvm-commits] [llvm] r57049 - in
/llvm/trunk: lib/Analysis/ScalarEvolution.cpp
test/Transforms/IndVarsSimplify/2008-10-03-CouldNotCompute.ll
In-Reply-To: <0AF89826-5395-4C39-854F-62BEAB4A039A@apple.com>
References: <200810041119.m94BJ7Lo019402@zion.cs.uiuc.edu>
<0AF89826-5395-4C39-854F-62BEAB4A039A@apple.com>
Message-ID: <48EAF213.4060302@mxc.ca>
Dan Gohman wrote:
> Hi Nick,
>
> Is this the right approach? It would be much simpler to just
> fix evaluateAtIteration to check for return value of
> BinomialCoefficient for CNC and stop trying to do further
> computation.
>
> Or, are you envisioning someday adding code that would want
> to take advantage of being able to keep going after getting
> a CNC, because it's simpler to do so, or in hopes that it
> might be cancelled out later?
No, it isn't. I took the idea that CNC * 0 -> 0 and generalized it to
the notion that we need to analyze these. We don't. For example, CNC -
CNC != 0.
I think your suggested fix is the right one. I'll put a patch in PR2857
soon/eventually.
Nick
> Also, in the patch, there are several instances of code like this:
>
>> + if (isa(Op))
>> + return new SCEVCouldNotCompute();
>
> Instead of creating a new SCEV object, code like this can
> just return Op.
>
> Dan
>
> On Oct 4, 2008, at 4:19 AM, Nick Lewycky wrote:
>
>> Author: nicholas
>> Date: Sat Oct 4 06:19:07 2008
>> New Revision: 57049
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=57049&view=rev
>> Log:
>> Allow the construction of SCEVs with SCEVCouldNotCompute operands, by
>> implementing folding. Fixes PR2857.
>>
>> Added:
>> llvm/trunk/test/Transforms/IndVarsSimplify/2008-10-03-
>> CouldNotCompute.ll
>> Modified:
>> llvm/trunk/lib/Analysis/ScalarEvolution.cpp
>>
>> Modified: llvm/trunk/lib/Analysis/ScalarEvolution.cpp
>> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Analysis/ScalarEvolution.cpp?rev=57049&r1=57048&r2=57049&view=diff
>>
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> ======================================================================
>> --- llvm/trunk/lib/Analysis/ScalarEvolution.cpp (original)
>> +++ llvm/trunk/lib/Analysis/ScalarEvolution.cpp Sat Oct 4 06:19:07
>> 2008
>> @@ -676,6 +676,9 @@
>> return getAddRecExpr(Operands, AddRec->getLoop());
>> }
>>
>> + if (isa(Op))
>> + return new SCEVCouldNotCompute();
>> +
>> SCEVTruncateExpr *&Result = (*SCEVTruncates)[std::make_pair(Op,
>> Ty)];
>> if (Result == 0) Result = new SCEVTruncateExpr(Op, Ty);
>> return Result;
>> @@ -691,6 +694,9 @@
>> // operands (often constants). This would allow analysis of
>> something like
>> // this: for (unsigned char X = 0; X < 100; ++X) { int Y = X; }
>>
>> + if (isa(Op))
>> + return new SCEVCouldNotCompute();
>> +
>> SCEVZeroExtendExpr *&Result = (*SCEVZeroExtends)
>> [std::make_pair(Op, Ty)];
>> if (Result == 0) Result = new SCEVZeroExtendExpr(Op, Ty);
>> return Result;
>> @@ -706,6 +712,9 @@
>> // operands (often constants). This would allow analysis of
>> something like
>> // this: for (signed char X = 0; X < 100; ++X) { int Y = X; }
>>
>> + if (isa(Op))
>> + return new SCEVCouldNotCompute();
>> +
>> SCEVSignExtendExpr *&Result = (*SCEVSignExtends)
>> [std::make_pair(Op, Ty)];
>> if (Result == 0) Result = new SCEVSignExtendExpr(Op, Ty);
>> return Result;
>> @@ -734,6 +743,10 @@
>> // Sort by complexity, this groups all similar expression types
>> together.
>> GroupByComplexity(Ops);
>>
>> + // Could not compute plus anything equals could not compute.
>> + if (isa(Ops.back()))
>> + return new SCEVCouldNotCompute();
>> +
>> // If there are any constants, fold them together.
>> unsigned Idx = 0;
>> if (SCEVConstant *LHSC = dyn_cast(Ops[0])) {
>> @@ -959,6 +972,21 @@
>> // Sort by complexity, this groups all similar expression types
>> together.
>> GroupByComplexity(Ops);
>>
>> + if (isa(Ops.back())) {
>> + // CNC * 0 = 0
>> + for (unsigned i = 0, e = Ops.size() - 1; i != e; ++i) {
>> + if (Ops[i]->getSCEVType() != scConstant)
>> + break;
>> +
>> + SCEVConstant *SC = cast(Ops[i]);
>> + if (SC->getValue()->isMinValue(false))
>> + return SC;
>> + }
>> +
>> + // Otherwise, we can't compute it.
>> + return new SCEVCouldNotCompute();
>> + }
>> +
>> // If there are any constants, fold them together.
>> unsigned Idx = 0;
>> if (SCEVConstant *LHSC = dyn_cast(Ops[0])) {
>> @@ -1124,6 +1152,9 @@
>>
>> // FIXME: implement folding of (X*4)/4 when we know X*4 doesn't
>> overflow.
>>
>> + if (isa(LHS) || isa(RHS))
>> + return new SCEVCouldNotCompute();
>> +
>> SCEVUDivExpr *&Result = (*SCEVUDivs)[std::make_pair(LHS, RHS)];
>> if (Result == 0) Result = new SCEVUDivExpr(LHS, RHS);
>> return Result;
>> @@ -1171,6 +1202,12 @@
>> }
>> }
>>
>> + // Refuse to build an AddRec out of SCEVCouldNotCompute.
>> + for (unsigned i = 0, e = Operands.size(); i != e; ++i) {
>> + if (isa(Operands[i]))
>> + return new SCEVCouldNotCompute();
>> + }
>> +
>> SCEVAddRecExpr *&Result =
>> (*SCEVAddRecExprs)[std::make_pair(L,
>> std::vector(Operands.begin(),
>>
>> Operands.end()))];
>> @@ -1193,6 +1230,21 @@
>> // Sort by complexity, this groups all similar expression types
>> together.
>> GroupByComplexity(Ops);
>>
>> + if (isa(Ops.back())) {
>> + // CNC smax +inf = +inf.
>> + for (unsigned i = 0, e = Ops.size() - 1; i != e; ++i) {
>> + if (Ops[i]->getSCEVType() != scConstant)
>> + break;
>> +
>> + SCEVConstant *SC = cast(Ops[i]);
>> + if (SC->getValue()->isMaxValue(true))
>> + return SC;
>> + }
>> +
>> + // Otherwise, we can't compute it.
>> + return new SCEVCouldNotCompute();
>> + }
>> +
>> // If there are any constants, fold them together.
>> unsigned Idx = 0;
>> if (SCEVConstant *LHSC = dyn_cast(Ops[0])) {
>> @@ -1273,6 +1325,21 @@
>> // Sort by complexity, this groups all similar expression types
>> together.
>> GroupByComplexity(Ops);
>>
>> + if (isa(Ops[0])) {
>> + // CNC umax inf = inf.
>> + for (unsigned i = 0, e = Ops.size() - 1; i != e; ++i) {
>> + if (Ops[i]->getSCEVType() != scConstant)
>> + break;
>> +
>> + SCEVConstant *SC = cast(Ops[i]);
>> + if (SC->getValue()->isMaxValue(false))
>> + return SC;
>> + }
>> +
>> + // Otherwise, we can't compute it.
>> + return new SCEVCouldNotCompute();
>> + }
>> +
>> // If there are any constants, fold them together.
>> unsigned Idx = 0;
>> if (SCEVConstant *LHSC = dyn_cast(Ops[0])) {
>>
>> Added: llvm/trunk/test/Transforms/IndVarsSimplify/2008-10-03-
>> CouldNotCompute.ll
>> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Transforms/IndVarsSimplify/2008-10-03-CouldNotCompute.ll?rev=57049&view=auto
>>
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> ======================================================================
>> --- llvm/trunk/test/Transforms/IndVarsSimplify/2008-10-03-
>> CouldNotCompute.ll (added)
>> +++ llvm/trunk/test/Transforms/IndVarsSimplify/2008-10-03-
>> CouldNotCompute.ll Sat Oct 4 06:19:07 2008
>> @@ -0,0 +1,32 @@
>> +; RUN: llvm-as < %s | opt -indvars
>> +; PR2857
>> +
>> + at foo = external global i32 ; [#uses=1]
>> +
>> +define void @test(i32 %n, i32 %arg) {
>> +entry:
>> + br i1 false, label %bb.nph, label %return
>> +
>> +bb.nph: ; preds = %entry
>> + %0 = load i32* @foo, align 4 ; [#uses=1]
>> + %1 = sext i32 %0 to i64 ; [#uses=1]
>> + br label %bb
>> +
>> +bb: ; preds = %bb, %bb.nph
>> + %.in = phi i32 [ %2, %bb ], [ %n, %bb.nph ] ; [#uses=1]
>> + %val.02 = phi i64 [ %5, %bb ], [ 0, %bb.nph ] ; [#uses=2]
>> + %result.01 = phi i64 [ %4, %bb ], [ 0, %bb.nph ] ; [#uses=1]
>> + %2 = add i32 %.in, -1 ; [#uses=2]
>> + %3 = mul i64 %1, %val.02 ; [#uses=1]
>> + %4 = add i64 %3, %result.01 ; [#uses=2]
>> + %5 = add i64 %val.02, 1 ; [#uses=1]
>> + %6 = icmp sgt i32 %2, 0 ; [#uses=1]
>> + br i1 %6, label %bb, label %bb3.bb4_crit_edge
>> +
>> +bb3.bb4_crit_edge: ; preds = %bb
>> + %.lcssa = phi i64 [ %4, %bb ] ; [#uses=0]
>> + ret void
>> +
>> +return: ; preds = %entry
>> + ret void
>> +}
>>
>>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
From andrewl at lenharth.org Tue Oct 7 00:27:09 2008
From: andrewl at lenharth.org (Andrew Lenharth)
Date: Tue, 7 Oct 2008 00:27:09 -0500
Subject: [llvm-commits] [llvm] r57226 - in /llvm/trunk:
include/llvm/Intrinsics.td include/llvm/IntrinsicsAlpha.td
lib/Target/Alpha/AlphaISelDAGToDAG.cpp
lib/Target/Alpha/AlphaISelLowering.cpp
In-Reply-To: <1589FB2C-9155-4943-9BEB-B775B11DFCB8@apple.com>
References: <200810070210.m972AUxl026421@zion.cs.uiuc.edu>
<1589FB2C-9155-4943-9BEB-B775B11DFCB8@apple.com>
Message-ID: <85dfcd7f0810062227i254c940cvaaa6152c108c55ea@mail.gmail.com>
On Mon, Oct 6, 2008 at 11:04 PM, Chris Lattner wrote:
>
> On Oct 6, 2008, at 7:10 PM, Andrew Lenharth wrote:
>
>> Author: alenhar2
>> Date: Mon Oct 6 21:10:26 2008
>> New Revision: 57226
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=57226&view=rev
>> Log:
>> Note that ADDC and company don't actually expand yet (missing in legalize
>
> Hi Andrew,
>
> __builtin_alpha_umulh can be represented with generic LLVM IR (zext to i128,
> multiply, shr by 64, truncate to i64). You should get good code for that
> sequence already, if not, that's a bug.
>
> Can you just have llvm-gcc expand the builtin like we do for other builtins
> supported by LLVM IR?
I was thinking of doing that, but I hadn't tried to see what kind of
code I got for it.
Andrew
From ggreif at gmail.com Tue Oct 7 01:41:03 2008
From: ggreif at gmail.com (Gabor Greif)
Date: Tue, 07 Oct 2008 06:41:03 -0000
Subject: [llvm-commits] [llvm] r57237 - in /llvm/trunk/test/FrontendObjC:
2008-10-3-EhValue.m 2008-10-3-EhValue.mm
Message-ID: <200810070641.m976f3Ul003977@zion.cs.uiuc.edu>
Author: ggreif
Date: Tue Oct 7 01:41:02 2008
New Revision: 57237
URL: http://llvm.org/viewvc/llvm-project?rev=57237&view=rev
Log:
fix filetype suffix
Added:
llvm/trunk/test/FrontendObjC/2008-10-3-EhValue.m (props changed)
- copied unchanged from r57236, llvm/trunk/test/FrontendObjC/2008-10-3-EhValue.mm
Removed:
llvm/trunk/test/FrontendObjC/2008-10-3-EhValue.mm
Propchange: llvm/trunk/test/FrontendObjC/2008-10-3-EhValue.m
------------------------------------------------------------------------------
svn:mergeinfo =
Removed: llvm/trunk/test/FrontendObjC/2008-10-3-EhValue.mm
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/FrontendObjC/2008-10-3-EhValue.mm?rev=57236&view=auto
==============================================================================
--- llvm/trunk/test/FrontendObjC/2008-10-3-EhValue.mm (original)
+++ llvm/trunk/test/FrontendObjC/2008-10-3-EhValue.mm (removed)
@@ -1,50 +0,0 @@
-// RUN: %llvmgcc -w -x objective-c -c %s -o /dev/null
-
- at interface Object {
- at public
- Class isa;
-}
-+initialize;
-+alloc;
-+new;
-+free;
--free;
-+(Class)class;
--(Class)class;
--init;
--superclass;
--(const char *)name;
- at end
-
- at interface Frob: Object
- at end
-
- at implementation Frob: Object
- at end
-
-static Frob* _connection = ((void *)0);
-
-extern void abort(void);
-
-void test (Object* sendPort)
-{
- int cleanupPorts = 1;
- Frob* receivePort = ((void *)0);
-
- @try {
- receivePort = (Frob *) -1;
- _connection = (Frob *) -1;
- receivePort = ((void *)0);
- sendPort = ((void *)0);
- cleanupPorts = 0;
- @throw [Object new];
- }
- @catch(Frob *obj) {
- if(!(0)) abort();
- }
- @catch(id exc) {
- if(!(!receivePort)) abort();
- if(!(!sendPort)) abort();
- if(!(!cleanupPorts)) abort();
- }
-}
From baldrick at free.fr Tue Oct 7 02:59:05 2008
From: baldrick at free.fr (Duncan Sands)
Date: Tue, 7 Oct 2008 09:59:05 +0200
Subject: [llvm-commits] [llvm-gcc-4.2] r57199 -
/llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
In-Reply-To: <200810062006.m96K656I011430@zion.cs.uiuc.edu>
References: <200810062006.m96K656I011430@zion.cs.uiuc.edu>
Message-ID: <200810070959.05307.baldrick@free.fr>
Hi Evan,
> /// EmitFILTER_EXPR - Handle FILTER_EXPR.
> Value *TreeToLLVM::EmitFILTER_EXPR(tree exp) {
> CreateExceptionValues();
> // Load exception selector.
> - return Builder.CreateLoad(ExceptionSelectorValue, "eh_select");
> + Value *V = Builder.CreateLoad(ExceptionSelectorValue, "eh_select");
> + // Cast the address to the right pointer type.
> + return BitCastToType(V, ConvertType(TREE_TYPE(exp)));
> }
I don't think this is right. Are you really seeing problems
with FILTER_EXPR? The big difference between EXC_PTR_EXPR and
FILTER_EXPR is that EXC_PTR_EXPR is a pointer while FILTER_EXPR
is an integer. We (and gcc generic code) treat EXC_PTR_EXPR
as a void*, while objc gives it a different pointer type. That
can be fixed by just bitcasting pointer types.
However if FILTER_EXPR is declared somewhere as an integer with
a different width then that's more problematic (and the bitcast
you introduced will assert!). Fortunately no-one besides the
core gcc eh code creates FILTER_EXPRs, not even objc, and the
places that do make them all use the same type.
In short, can you please revert the FILTER_EXPR parts of the
patch.
Thanks,
Duncan.
From baldrick at free.fr Tue Oct 7 03:04:07 2008
From: baldrick at free.fr (Duncan Sands)
Date: Tue, 7 Oct 2008 10:04:07 +0200
Subject: [llvm-commits] [poolalloc] r57214 -
/poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp
In-Reply-To: <200810062229.m96MToU0017479@zion.cs.uiuc.edu>
References: <200810062229.m96MToU0017479@zion.cs.uiuc.edu>
Message-ID: <200810071004.07554.baldrick@free.fr>
> + CallSite(NewCall).setCallingConv(CallSite(TheCall).getCallingConv());
Don't forget tail call markings and parameter attributes.
Ciao,
Duncan.
PS: These things are too easy to forget - there should really be some
helpers that take care of this kind of thing...
From baldrick at free.fr Tue Oct 7 03:13:20 2008
From: baldrick at free.fr (Duncan Sands)
Date: Tue, 7 Oct 2008 10:13:20 +0200
Subject: [llvm-commits] [llvm] r57167 - in /llvm/trunk: configure
test/FrontendObjC++/dg.exp test/lib/llvm.exp
In-Reply-To: <2A7F209F-0677-40E9-AFF4-EADE5D94AB44@apple.com>
References: <200810061031.m96AVU4e024330@zion.cs.uiuc.edu>
<2A7F209F-0677-40E9-AFF4-EADE5D94AB44@apple.com>
Message-ID: <200810071013.21014.baldrick@free.fr>
Hi Tanya,
> Did you forget to check in autoconf/configure.ac?
yeah, I forgot how configure works :)
How about this?
Ciao,
Duncan.
PS: I don't have the right autothing version to regenerate configure.
Index: autoconf/configure.ac
===================================================================
--- autoconf/configure.ac (revision 57238)
+++ autoconf/configure.ac (working copy)
@@ -872,7 +872,7 @@
llvmgccmajvers=[`echo $llvmgccversion | sed 's/^\([0-9]\).*/\1/'`]
AC_SUBST(LLVMGCC_VERSION,$llvmgccversion)
AC_SUBST(LLVMGCC_MAJVERS,$llvmgccmajvers)
- llvmgcclangs=[`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ -]*\).*/\1/'`]
+ llvmgcclangs=[`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ ]*\).*/\1/'`]
AC_SUBST(LLVMGCC_LANGS,$llvmgcclangs)
AC_MSG_RESULT([ok])
fi
From matthijs at stdin.nl Tue Oct 7 05:03:48 2008
From: matthijs at stdin.nl (Matthijs Kooijman)
Date: Tue, 07 Oct 2008 10:03:48 -0000
Subject: [llvm-commits] [llvm] r57239 - /llvm/trunk/docs/LangRef.html
Message-ID: <200810071003.m97A3mlD020411@zion.cs.uiuc.edu>
Author: matthijs
Date: Tue Oct 7 05:03:45 2008
New Revision: 57239
URL: http://llvm.org/viewvc/llvm-project?rev=57239&view=rev
Log:
Add two forgotten 's.
Modified:
llvm/trunk/docs/LangRef.html
Modified: llvm/trunk/docs/LangRef.html
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/LangRef.html?rev=57239&r1=57238&r2=57239&view=diff
==============================================================================
--- llvm/trunk/docs/LangRef.html (original)
+++ llvm/trunk/docs/LangRef.html Tue Oct 7 05:03:45 2008
@@ -4333,8 +4333,8 @@
%r = call %struct.A @foo() ; yields { 32, i8 }
%gr = extractvalue %struct.A %r, 0 ; yields i32
%gr1 = extractvalue %struct.A %r, 1 ; yields i8
- %Z = call void @foo() noreturn ; indicates that foo never returns nomrally
- %ZZ = call zeroext i32 @bar() ; Return value is zero extended
+ %Z = call void @foo() noreturn ; indicates that %foo never returns nomrally
+ %ZZ = call zeroext i32 @bar() ; Return value is %zero extended
From andrewl at lenharth.org Tue Oct 7 08:18:04 2008
From: andrewl at lenharth.org (Andrew Lenharth)
Date: Tue, 7 Oct 2008 08:18:04 -0500
Subject: [llvm-commits] [poolalloc] r57214 -
/poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp
In-Reply-To: <200810071004.07554.baldrick@free.fr>
References: <200810062229.m96MToU0017479@zion.cs.uiuc.edu>
<200810071004.07554.baldrick@free.fr>
Message-ID: <85dfcd7f0810070618s1e3167f3hddf370d435b2722f@mail.gmail.com>
On Tue, Oct 7, 2008 at 3:04 AM, Duncan Sands wrote:
>> + CallSite(NewCall).setCallingConv(CallSite(TheCall).getCallingConv());
>
> Don't forget tail call markings and parameter attributes.
Thanks, the tail call markings I was still looking into. The parameter
attributes are handled during the function clone/rewriting (but suffer
from potential off by one errors, parameter attributes should really
be properties of the Argument class rather than positional in the
Function class).
Andrew
From neil at daikokuya.co.uk Tue Oct 7 08:19:21 2008
From: neil at daikokuya.co.uk (Neil Booth)
Date: Tue, 7 Oct 2008 22:19:21 +0900
Subject: [llvm-commits] [llvm] r57185
- /llvm/trunk/lib/Support/APFloat.cpp
In-Reply-To: <0C450614-92AA-4337-B0EA-53797DA53326@apple.com>
References: <200810061822.m96IMTgD007250@zion.cs.uiuc.edu>
<0C450614-92AA-4337-B0EA-53797DA53326@apple.com>
Message-ID: <20081007131921.GF19669@daikokuya.co.uk>
Dale Johannesen wrote:-
>
> On Oct 6, 2008, at 11:51 AMPDT, Dan Gohman wrote:
> >>
> >> + fs = (shift < 0) ? opInexact : opOK;
> >> // gcc forces the Quiet bit on, which means (float)(double)
> >> (float_sNan)
> >> // does not give you back the same bits. This is dubious, and we
> >> // don't currently do it. You're really supposed to get
> >> // an invalid operation signal at runtime, but nobody does that.
> >> - fs = opOK;
> >
> > Shouldn't converting a NaN set the opInvalidOp flag?
>
> According to IEEE754, converting a SNan sets opInvalid, but we aren't
> really trying for an accurate implementation of SNan's (nor does the
> OS).
>
> For converting a QNan, what it says is:
> "Every operation involving one or two input NaNs, none of them
> signaling, shall signal no exception but, if a FP result is to be
> delivered, shall deliver as its result a QNaN, which should be one of
> the input NaNs. Note that format conversions might be unable to
> deliver the same NaN."
>
> The last sentence applies here, and I'm not sure of its intent. At
> face value it's a statement that it may be impossible to implement the
> standard in this case, which seems unlikely. IMO an Inexact result
> seems compatible with the way things work otherwise.
>
> To confuse things further, the value in the PR is not even an IEEE
> NaN, but a pseudo-NaN in Intel jargon. It is outside all standards.
The intent of APFloat as I wrote it was to replicate a conforming
IEEE-754 CPU's results in software, with the return result indicating
those exceptions that would occur under IEEE-754. IBM double double
was later hacked on in an incomplete way.
The paragraph you quote is unambiguous; these NaN to NaN conversions
should always return fsOK because it "shall signal no exception".
This is how the code worked before your change.
Perhaps LLVM needs APFloat to evolve beyond IEEE-754; I'm not sure.
But I suggest you think hard about that, and if you decide to go that
way you at least use a new flag for your extensions. You should
also update the comments in the .cpp and .h files appropriately,
and review what other changes, if any, to other operations are needed
to accomdate your new semantics.
Neil.
From neil at daikokuya.co.uk Tue Oct 7 08:21:39 2008
From: neil at daikokuya.co.uk (Neil Booth)
Date: Tue, 7 Oct 2008 22:21:39 +0900
Subject: [llvm-commits] [llvm] r57224
- /llvm/trunk/lib/Support/APFloat.cpp
In-Reply-To: <200810070040.m970e3G9022211@zion.cs.uiuc.edu>
References: <200810070040.m970e3G9022211@zion.cs.uiuc.edu>
Message-ID: <20081007132139.GG19669@daikokuya.co.uk>
Dale Johannesen wrote:-
> Author: johannes
> Date: Mon Oct 6 19:40:01 2008
> New Revision: 57224
>
> URL: http://llvm.org/viewvc/llvm-project?rev=57224&view=rev
> Log:
> Mark negative-zero-to-int conversion as Inexact,
> since -0.0 can't be represented as an int.
> This prevents llvm from reducing -0.0 to a
> load-and-convert of int 0. Fixes
> ieee.exp/mzero[2356].c in gcc testsuite.
>
>
> Modified:
> llvm/trunk/lib/Support/APFloat.cpp
>
> Modified: llvm/trunk/lib/Support/APFloat.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/APFloat.cpp?rev=57224&r1=57223&r2=57224&view=diff
>
> ==============================================================================
> --- llvm/trunk/lib/Support/APFloat.cpp (original)
> +++ llvm/trunk/lib/Support/APFloat.cpp Mon Oct 6 19:40:01 2008
> @@ -1784,7 +1784,8 @@
>
> if(category == fcZero) {
> APInt::tcSet(parts, 0, dstPartsCount);
> - return opOK;
> + // Negative zero can't be represented as an int.
> + return sign ? opInexact : opOK;
> }
See my other mail. This and your other changes is abandoning the
original intent of APFloat, to become some kind of fuzzy semantics.
I am not in favour of this.
Neil.
From neil at daikokuya.co.uk Tue Oct 7 08:31:55 2008
From: neil at daikokuya.co.uk (Neil Booth)
Date: Tue, 7 Oct 2008 22:31:55 +0900
Subject: [llvm-commits] [llvm] r57185
- /llvm/trunk/lib/Support/APFloat.cpp
In-Reply-To: <20081007131921.GF19669@daikokuya.co.uk>
References: <200810061822.m96IMTgD007250@zion.cs.uiuc.edu>
<0C450614-92AA-4337-B0EA-53797DA53326@apple.com>
<20081007131921.GF19669@daikokuya.co.uk>
Message-ID: <20081007133155.GH19669@daikokuya.co.uk>
Neil Booth wrote:-
> > For converting a QNan, what it says is:
> > "Every operation involving one or two input NaNs, none of them
> > signaling, shall signal no exception but, if a FP result is to be
> > delivered, shall deliver as its result a QNaN, which should be one of
> > the input NaNs. Note that format conversions might be unable to
> > deliver the same NaN."
> >
> > The last sentence applies here, and I'm not sure of its intent. At
> > face value it's a statement that it may be impossible to implement the
> > standard in this case, which seems unlikely. IMO an Inexact result
> > seems compatible with the way things work otherwise.
> >
> > To confuse things further, the value in the PR is not even an IEEE
> > NaN, but a pseudo-NaN in Intel jargon. It is outside all standards.
>
> The intent of APFloat as I wrote it was to replicate a conforming
> IEEE-754 CPU's results in software, with the return result indicating
> those exceptions that would occur under IEEE-754. IBM double double
> was later hacked on in an incomplete way.
>
> The paragraph you quote is unambiguous; these NaN to NaN conversions
> should always return fsOK because it "shall signal no exception".
> This is how the code worked before your change.
>
> Perhaps LLVM needs APFloat to evolve beyond IEEE-754; I'm not sure.
> But I suggest you think hard about that, and if you decide to go that
> way you at least use a new flag for your extensions. You should
> also update the comments in the .cpp and .h files appropriately,
> and review what other changes, if any, to other operations are needed
> to accomdate your new semantics.
I missed your bit about this being some Intel 80-bit format extension
thing. If so, we should replicate the exceptions done by a real
Intel / AMD CPU. I don't believe they define extra exceptions.
What exceptions do they raise and what result do they give in this
case? Do we match both?
Neil.
From alenhar2 at cs.uiuc.edu Tue Oct 7 09:15:44 2008
From: alenhar2 at cs.uiuc.edu (Andrew Lenharth)
Date: Tue, 07 Oct 2008 14:15:44 -0000
Subject: [llvm-commits] [llvm] r57243 - in /llvm/trunk:
lib/CodeGen/SelectionDAG/LegalizeDAG.cpp test/CodeGen/Alpha/add128.ll
test/CodeGen/Alpha/sub128.ll
Message-ID: <200810071415.m97EFi63028661@zion.cs.uiuc.edu>
Author: alenhar2
Date: Tue Oct 7 09:15:42 2008
New Revision: 57243
URL: http://llvm.org/viewvc/llvm-project?rev=57243&view=rev
Log:
Expand arith on machines without carry flags
Added:
llvm/trunk/test/CodeGen/Alpha/sub128.ll
Modified:
llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
llvm/trunk/test/CodeGen/Alpha/add128.ll
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp?rev=57243&r1=57242&r2=57243&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp Tue Oct 7 09:15:42 2008
@@ -6431,7 +6431,6 @@
break;
}
}
-
// Expand the subcomponents.
SDValue LHSL, LHSH, RHSL, RHSH;
ExpandOp(Node->getOperand(0), LHSL, LHSH);
@@ -6442,16 +6441,41 @@
LoOps[1] = RHSL;
HiOps[0] = LHSH;
HiOps[1] = RHSH;
- if (Node->getOpcode() == ISD::ADD) {
- Lo = DAG.getNode(ISD::ADDC, VTList, LoOps, 2);
- HiOps[2] = Lo.getValue(1);
- Hi = DAG.getNode(ISD::ADDE, VTList, HiOps, 3);
+ if(TLI.isOperationLegal(ISD::ADDC, NVT)) {
+ if (Node->getOpcode() == ISD::ADD) {
+ Lo = DAG.getNode(ISD::ADDC, VTList, LoOps, 2);
+ HiOps[2] = Lo.getValue(1);
+ Hi = DAG.getNode(ISD::ADDE, VTList, HiOps, 3);
+ } else {
+ Lo = DAG.getNode(ISD::SUBC, VTList, LoOps, 2);
+ HiOps[2] = Lo.getValue(1);
+ Hi = DAG.getNode(ISD::SUBE, VTList, HiOps, 3);
+ }
+ break;
} else {
- Lo = DAG.getNode(ISD::SUBC, VTList, LoOps, 2);
- HiOps[2] = Lo.getValue(1);
- Hi = DAG.getNode(ISD::SUBE, VTList, HiOps, 3);
+ if (Node->getOpcode() == ISD::ADD) {
+ Lo = DAG.getNode(ISD::ADD, VTList, LoOps, 2);
+ Hi = DAG.getNode(ISD::ADD, VTList, HiOps, 2);
+ SDValue Cmp1 = DAG.getSetCC(NVT, Lo, LoOps[0], ISD::SETULT);
+ SDValue Carry1 = DAG.getNode(ISD::SELECT, NVT, Cmp1,
+ DAG.getConstant(1, NVT),
+ DAG.getConstant(0, NVT));
+ SDValue Cmp2 = DAG.getSetCC(NVT, Lo, LoOps[1], ISD::SETULT);
+ SDValue Carry2 = DAG.getNode(ISD::SELECT, NVT, Cmp2,
+ DAG.getConstant(1, NVT),
+ Carry1);
+ Hi = DAG.getNode(ISD::ADD, NVT, Hi, Carry2);
+ } else {
+ Lo = DAG.getNode(ISD::SUB, VTList, LoOps, 2);
+ Hi = DAG.getNode(ISD::SUB, VTList, HiOps, 2);
+ SDValue Cmp = DAG.getSetCC(NVT, LoOps[0], LoOps[1], ISD::SETULT);
+ SDValue Borrow = DAG.getNode(ISD::SELECT, NVT, Cmp,
+ DAG.getConstant(1, NVT),
+ DAG.getConstant(0, NVT));
+ Hi = DAG.getNode(ISD::SUB, NVT, Hi, Borrow);
+ }
+ break;
}
- break;
}
case ISD::ADDC:
Modified: llvm/trunk/test/CodeGen/Alpha/add128.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Alpha/add128.ll?rev=57243&r1=57242&r2=57243&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/Alpha/add128.ll (original)
+++ llvm/trunk/test/CodeGen/Alpha/add128.ll Tue Oct 7 09:15:42 2008
@@ -1,7 +1,6 @@
;test for ADDC and ADDE expansion
;
; RUN: llvm-as < %s | llc -march=alpha
-; XFAIL: *
define i128 @add128(i128 %x, i128 %y) {
entry:
Added: llvm/trunk/test/CodeGen/Alpha/sub128.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Alpha/sub128.ll?rev=57243&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/Alpha/sub128.ll (added)
+++ llvm/trunk/test/CodeGen/Alpha/sub128.ll Tue Oct 7 09:15:42 2008
@@ -0,0 +1,9 @@
+;test for SUBC and SUBE expansion
+;
+; RUN: llvm-as < %s | llc -march=alpha
+
+define i128 @sub128(i128 %x, i128 %y) {
+entry:
+ %tmp = sub i128 %y, %x
+ ret i128 %tmp
+}
From andrewl at lenharth.org Tue Oct 7 09:35:59 2008
From: andrewl at lenharth.org (Andrew Lenharth)
Date: Tue, 7 Oct 2008 09:35:59 -0500
Subject: [llvm-commits] [poolalloc] r57214 -
/poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp
In-Reply-To: <85dfcd7f0810070618s1e3167f3hddf370d435b2722f@mail.gmail.com>
References: <200810062229.m96MToU0017479@zion.cs.uiuc.edu>
<200810071004.07554.baldrick@free.fr>
<85dfcd7f0810070618s1e3167f3hddf370d435b2722f@mail.gmail.com>
Message-ID: <85dfcd7f0810070735m2a820118vcb2779c1c110ce01@mail.gmail.com>
On Tue, Oct 7, 2008 at 8:18 AM, Andrew Lenharth wrote:
> On Tue, Oct 7, 2008 at 3:04 AM, Duncan Sands wrote:
>>> + CallSite(NewCall).setCallingConv(CallSite(TheCall).getCallingConv());
>>
>> Don't forget tail call markings and parameter attributes.
>
> Thanks, the tail call markings I was still looking into. The parameter
> attributes are handled during the function clone/rewriting (but suffer
> from potential off by one errors, parameter attributes should really
> be properties of the Argument class rather than positional in the
> Function class).
Actually, it's not clear, does one have to specify parameter
attributes on the call site too? I was under the impression they just
were for the functions. hmm...
Andrew
From alenhar2 at cs.uiuc.edu Tue Oct 7 09:41:04 2008
From: alenhar2 at cs.uiuc.edu (Andrew Lenharth)
Date: Tue, 07 Oct 2008 14:41:04 -0000
Subject: [llvm-commits] [llvm-gcc-4.2] r57244 -
/llvm-gcc-4.2/trunk/gcc/config/alpha/llvm-alpha.cpp
Message-ID: <200810071441.m97Ef5A6029697@zion.cs.uiuc.edu>
Author: alenhar2
Date: Tue Oct 7 09:41:03 2008
New Revision: 57244
URL: http://llvm.org/viewvc/llvm-project?rev=57244&view=rev
Log:
expand to llmv IR
Modified:
llvm-gcc-4.2/trunk/gcc/config/alpha/llvm-alpha.cpp
Modified: llvm-gcc-4.2/trunk/gcc/config/alpha/llvm-alpha.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/config/alpha/llvm-alpha.cpp?rev=57244&r1=57243&r2=57244&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/config/alpha/llvm-alpha.cpp (original)
+++ llvm-gcc-4.2/trunk/gcc/config/alpha/llvm-alpha.cpp Tue Oct 7 09:41:03 2008
@@ -103,13 +103,13 @@
std::vector &Ops) {
switch (FnCode) {
case ALPHA_BUILTIN_UMULH: {
- Function *f =
- Intrinsic::getDeclaration(TheModule, Intrinsic::alpha_umulh);
Value *Arg0 = Ops[0];
Value *Arg1 = Ops[1];
- Value *CallOps[2] = { Arg0, Arg1};
- Result = Builder.CreateCall(f, CallOps, CallOps+2, "tmp");
- Result = Builder.CreateBitCast(Result, ResultType, "tmp");
+ Arg0 = Builder.CreateZExt(Arg0, IntegerType::get(128));
+ Arg1 = Builder.CreateZExt(Arg1, IntegerType::get(128));
+ Result = Builder.CreateMul(Arg0, Arg1);
+ Result = Builder.CreateLShr(Result, ConstantInt::get(Type::Int64Ty, 64));
+ Result = Builder.CreateTrunc(Result, Type::Int64Ty);
return true;
}
default: break;
From nunoplopes at sapo.pt Tue Oct 7 09:48:14 2008
From: nunoplopes at sapo.pt (Nuno Lopes)
Date: Tue, 07 Oct 2008 14:48:14 -0000
Subject: [llvm-commits] [llvm] r57245 - in /llvm/trunk/test: Makefile
lib/llvm.exp
Message-ID: <200810071448.m97EmE1u029909@zion.cs.uiuc.edu>
Author: nlopes
Date: Tue Oct 7 09:48:14 2008
New Revision: 57245
URL: http://llvm.org/viewvc/llvm-project?rev=57245&view=rev
Log:
add support for running the test suite with valgrind. to run it just type 'make VG=1', as in clang
beware of the 42000 leaks reported by valgrind in the Constant.cpp + Type.cpp files. it needs fixing IMHO
Modified:
llvm/trunk/test/Makefile
llvm/trunk/test/lib/llvm.exp
Modified: llvm/trunk/test/Makefile
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Makefile?rev=57245&r1=57244&r2=57245&view=diff
==============================================================================
--- llvm/trunk/test/Makefile (original)
+++ llvm/trunk/test/Makefile Tue Oct 7 09:48:14 2008
@@ -32,6 +32,10 @@
RUNTESTFLAGS += --tool $(CLEANED_TESTSUITE)
endif
+ifdef VG
+VALGRIND := valgrind --tool=memcheck --quiet --trace-children=yes --error-exitcode=3 --leak-check=full
+endif
+
IGNORE_TESTS :=
ifndef RUNLLVM2CPP
@@ -77,7 +81,9 @@
clean::
$(RM) -rf `find $(LLVM_OBJ_ROOT)/test -name Output -type d -print`
-site.exp: Makefile $(LLVM_OBJ_ROOT)/Makefile.config
+FORCE:
+
+site.exp: FORCE
@echo 'Making a new site.exp file...'
@echo '## these variables are automatically generated by make ##' >site.tmp
@echo '# Do not edit here. If you wish to override these values' >>site.tmp
@@ -103,6 +109,7 @@
@echo 'set llvmgccmajvers "$(LLVMGCC_MAJVERS)"' >> site.tmp
@echo 'set shlibext "$(SHLIBEXT)"' >> site.tmp
@echo 'set ocamlc "$(OCAMLC) -cc $(CXX) -I $(LibDir)/ocaml"' >> site.tmp
+ @echo 'set valgrind "$(VALGRIND)"' >> site.tmp
@echo '## All variables above are generated by configure. Do Not Edit ## ' >>site.tmp
@test ! -f site.exp || \
sed '1,/^## All variables above are.*##/ d' site.exp >> site.tmp
Modified: llvm/trunk/test/lib/llvm.exp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/lib/llvm.exp?rev=57245&r1=57244&r2=57245&view=diff
==============================================================================
--- llvm/trunk/test/lib/llvm.exp (original)
+++ llvm/trunk/test/lib/llvm.exp Tue Oct 7 09:48:14 2008
@@ -49,11 +49,14 @@
global srcroot objroot srcdir objdir subdir target_triplet prcontext
global llvmgcc llvmgxx llvmgcc_version llvmgccmajvers ocamlc
global gccpath gxxpath compile_c compile_cxx link shlibext llvmlibsdir
+ global valgrind
set path [file join $srcdir $subdir]
# Substitute all Tcl variables.
set new_line [subst $line ]
+ #replace %% with _#MARKER#_ to make the replacement of %% more predictable
+ regsub -all {%%} $new_line {_#MARKER#_} new_line
#replace %prcontext with prcontext.tcl (Must replace before %p)
regsub -all {%prcontext} $new_line $prcontext new_line
#replace %llvmgcc with actual path to llvmgcc
@@ -78,8 +81,28 @@
regsub -all {%s} $new_line $test new_line
#replace %t with temp filenames
regsub -all {%t} $new_line $tmpFile new_line
- #replace %% with %
- regsub -all {%%} $new_line % new_line
+ #replace _#MARKER#_ with %
+ regsub -all {_#MARKER#_} $new_line % new_line
+
+ #valgind related stuff
+# regsub -all {bugpoint } $new_line "$valgrind bugpoint " new_line
+ regsub -all {llc } $new_line "$valgrind llc " new_line
+ regsub -all {lli } $new_line "$valgrind lli " new_line
+ regsub -all {llvm-ar } $new_line "$valgrind llvm-ar " new_line
+ regsub -all {llvm-as } $new_line "$valgrind llvm-as " new_line
+ regsub -all {llvm-bcanalyzer } $new_line "$valgrind llvm-bcanalyzer " new_line
+ regsub -all {llvm-dis } $new_line "$valgrind llvm-dis " new_line
+ regsub -all {llvm-extract } $new_line "$valgrind llvm-extract " new_line
+ regsub -all {llvm-ld } $new_line "$valgrind llvm-ld " new_line
+ regsub -all {llvm-link } $new_line "$valgrind llvm-link " new_line
+ regsub -all {llvm-nm } $new_line "$valgrind llvm-nm " new_line
+ regsub -all {llvm-prof } $new_line "$valgrind llvm-prof " new_line
+ regsub -all {llvm-ranlib } $new_line "$valgrind llvm-ranlib " new_line
+ regsub -all {([^a-zA-Z_-])opt } $new_line "\\1$valgrind opt " new_line
+ regsub -all {^opt } $new_line "$valgrind opt " new_line
+ regsub -all {tblgen } $new_line "$valgrind tblgen " new_line
+ regsub -all "not $valgrind " $new_line "$valgrind not " new_line
+
return $new_line
}
From baldrick at free.fr Tue Oct 7 09:50:46 2008
From: baldrick at free.fr (Duncan Sands)
Date: Tue, 7 Oct 2008 16:50:46 +0200
Subject: [llvm-commits] [poolalloc] r57214 -
/poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp
In-Reply-To: <85dfcd7f0810070735m2a820118vcb2779c1c110ce01@mail.gmail.com>
References: <200810062229.m96MToU0017479@zion.cs.uiuc.edu>
<85dfcd7f0810070618s1e3167f3hddf370d435b2722f@mail.gmail.com>
<85dfcd7f0810070735m2a820118vcb2779c1c110ce01@mail.gmail.com>
Message-ID: <200810071650.47091.baldrick@free.fr>
> > Thanks, the tail call markings I was still looking into. The parameter
> > attributes are handled during the function clone/rewriting (but suffer
> > from potential off by one errors, parameter attributes should really
> > be properties of the Argument class rather than positional in the
> > Function class).
>
> Actually, it's not clear, does one have to specify parameter
> attributes on the call site too? I was under the impression they just
> were for the functions. hmm...
Yes, you should. This is needed for indirect calls, also
in some situations stronger information is available on
the call than on the function.
Ciao,
Duncan.
PS: I agree that parameter attributes are currently a pain to
work with - it would be simpler if they were somehow attached
to the Argument class.
From lattner at apple.com Tue Oct 7 10:52:03 2008
From: lattner at apple.com (Tanya Lattner)
Date: Tue, 7 Oct 2008 08:52:03 -0700
Subject: [llvm-commits] [llvm] r57167 - in /llvm/trunk: configure
test/FrontendObjC++/dg.exp test/lib/llvm.exp
In-Reply-To: <200810071013.21014.baldrick@free.fr>
References: <200810061031.m96AVU4e024330@zion.cs.uiuc.edu>
<2A7F209F-0677-40E9-AFF4-EADE5D94AB44@apple.com>
<200810071013.21014.baldrick@free.fr>
Message-ID:
Thanks. I'll regenerate. If you ever need it done in the future, you
can bug me too.
-Tanya
On Oct 7, 2008, at 1:13 AM, Duncan Sands wrote:
> Hi Tanya,
>
>> Did you forget to check in autoconf/configure.ac?
>
> yeah, I forgot how configure works :)
>
> How about this?
>
> Ciao,
>
> Duncan.
>
> PS: I don't have the right autothing version to regenerate configure.
>
> Index: autoconf/configure.ac
> ===================================================================
> --- autoconf/configure.ac (revision 57238)
> +++ autoconf/configure.ac (working copy)
> @@ -872,7 +872,7 @@
> llvmgccmajvers=[`echo $llvmgccversion | sed 's/^\([0-9]\).*/\1/'`]
> AC_SUBST(LLVMGCC_VERSION,$llvmgccversion)
> AC_SUBST(LLVMGCC_MAJVERS,$llvmgccmajvers)
> - llvmgcclangs=[`"$LLVMGCC" -v --help 2>&1 | grep '^Configured
> with:' | sed 's/^.*--enable-languages=\([^ -]*\).*/\1/'`]
> + llvmgcclangs=[`"$LLVMGCC" -v --help 2>&1 | grep '^Configured
> with:' | sed 's/^.*--enable-languages=\([^ ]*\).*/\1/'`]
> AC_SUBST(LLVMGCC_LANGS,$llvmgcclangs)
> AC_MSG_RESULT([ok])
> fi
From andersca at mac.com Tue Oct 7 11:14:13 2008
From: andersca at mac.com (Anders Carlsson)
Date: Tue, 07 Oct 2008 16:14:13 -0000
Subject: [llvm-commits] [llvm] r57246 - in /llvm/trunk:
lib/Target/X86/X86InstrSSE.td test/CodeGen/X86/2008-10-07-SSEISelBug.ll
Message-ID: <200810071614.m97GEEHo000779@zion.cs.uiuc.edu>
Author: andersca
Date: Tue Oct 7 11:14:11 2008
New Revision: 57246
URL: http://llvm.org/viewvc/llvm-project?rev=57246&view=rev
Log:
Certain patterns involving the "movss" instruction were marked as requiring SSE2, when in reality movss is an SSE1 instruction.
Added:
llvm/trunk/test/CodeGen/X86/2008-10-07-SSEISelBug.ll
Modified:
llvm/trunk/lib/Target/X86/X86InstrSSE.td
Modified: llvm/trunk/lib/Target/X86/X86InstrSSE.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrSSE.td?rev=57246&r1=57245&r2=57246&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86InstrSSE.td (original)
+++ llvm/trunk/lib/Target/X86/X86InstrSSE.td Tue Oct 7 11:14:11 2008
@@ -2891,11 +2891,11 @@
def : Pat<(v2f64 (X86vzmovl (v2f64 (scalar_to_vector FR64:$src)))),
(MOVLSD2PDrr (V_SET0), FR64:$src)>, Requires<[HasSSE2]>;
def : Pat<(v4f32 (X86vzmovl (v4f32 (scalar_to_vector FR32:$src)))),
- (MOVLSS2PSrr (V_SET0), FR32:$src)>, Requires<[HasSSE2]>;
+ (MOVLSS2PSrr (V_SET0), FR32:$src)>, Requires<[HasSSE1]>;
def : Pat<(v4f32 (X86vzmovl (v4f32 VR128:$src))),
- (MOVLPSrr (V_SET0), VR128:$src)>, Requires<[HasSSE2]>;
+ (MOVLPSrr (V_SET0), VR128:$src)>, Requires<[HasSSE1]>;
def : Pat<(v4i32 (X86vzmovl (v4i32 VR128:$src))),
- (MOVLPSrr (V_SET0), VR128:$src)>, Requires<[HasSSE2]>;
+ (MOVLPSrr (V_SET0), VR128:$src)>, Requires<[HasSSE1]>;
}
// Splat v2f64 / v2i64
Added: llvm/trunk/test/CodeGen/X86/2008-10-07-SSEISelBug.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/2008-10-07-SSEISelBug.ll?rev=57246&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/X86/2008-10-07-SSEISelBug.ll (added)
+++ llvm/trunk/test/CodeGen/X86/2008-10-07-SSEISelBug.ll Tue Oct 7 11:14:11 2008
@@ -0,0 +1,22 @@
+; RUN: llvm-as < %s | llc -march=x86 -mattr=+sse,-sse2
+
+define <4 x float> @f(float %w) nounwind {
+entry:
+ %retval = alloca <4 x float> ; <<4 x float>*> [#uses=2]
+ %w.addr = alloca float ; [#uses=2]
+ %.compoundliteral = alloca <4 x float> ; <<4 x float>*> [#uses=2]
+ store float %w, float* %w.addr
+ %tmp = load float* %w.addr ; [#uses=1]
+ %0 = insertelement <4 x float> undef, float %tmp, i32 0 ; <<4 x float>> [#uses=1]
+ %1 = insertelement <4 x float> %0, float 0.000000e+00, i32 1 ; <<4 x float>> [#uses=1]
+ %2 = insertelement <4 x float> %1, float 0.000000e+00, i32 2 ; <<4 x float>> [#uses=1]
+ %3 = insertelement <4 x float> %2, float 0.000000e+00, i32 3 ; <<4 x float>> [#uses=1]
+ store <4 x float> %3, <4 x float>* %.compoundliteral
+ %tmp1 = load <4 x float>* %.compoundliteral ; <<4 x float>> [#uses=1]
+ store <4 x float> %tmp1, <4 x float>* %retval
+ br label %return
+
+return: ; preds = %entry
+ %4 = load <4 x float>* %retval ; <<4 x float>> [#uses=1]
+ ret <4 x float> %4
+}
From andrewl at lenharth.org Tue Oct 7 11:33:01 2008
From: andrewl at lenharth.org (Andrew Lenharth)
Date: Tue, 7 Oct 2008 11:33:01 -0500
Subject: [llvm-commits] [llvm] r57243 - in /llvm/trunk:
lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
test/CodeGen/Alpha/add128.ll test/CodeGen/Alpha/sub128.ll
In-Reply-To: <200810071415.m97EFi63028661@zion.cs.uiuc.edu>
References: <200810071415.m97EFi63028661@zion.cs.uiuc.edu>
Message-ID: <85dfcd7f0810070933t18226dd9m45c25c212dc66148@mail.gmail.com>
This breaks one test in Codegen/Generic on x86 (but not x86-64 or
alpha). Looking into it now.
Andrew
On Tue, Oct 7, 2008 at 9:15 AM, Andrew Lenharth wrote:
> Author: alenhar2
> Date: Tue Oct 7 09:15:42 2008
> New Revision: 57243
>
> URL: http://llvm.org/viewvc/llvm-project?rev=57243&view=rev
> Log:
> Expand arith on machines without carry flags
>
> Added:
> llvm/trunk/test/CodeGen/Alpha/sub128.ll
> Modified:
> llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
> llvm/trunk/test/CodeGen/Alpha/add128.ll
>
> Modified: llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp?rev=57243&r1=57242&r2=57243&view=diff
>
> ==============================================================================
> --- llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp (original)
> +++ llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp Tue Oct 7 09:15:42 2008
> @@ -6431,7 +6431,6 @@
> break;
> }
> }
> -
> // Expand the subcomponents.
> SDValue LHSL, LHSH, RHSL, RHSH;
> ExpandOp(Node->getOperand(0), LHSL, LHSH);
> @@ -6442,16 +6441,41 @@
> LoOps[1] = RHSL;
> HiOps[0] = LHSH;
> HiOps[1] = RHSH;
> - if (Node->getOpcode() == ISD::ADD) {
> - Lo = DAG.getNode(ISD::ADDC, VTList, LoOps, 2);
> - HiOps[2] = Lo.getValue(1);
> - Hi = DAG.getNode(ISD::ADDE, VTList, HiOps, 3);
> + if(TLI.isOperationLegal(ISD::ADDC, NVT)) {
> + if (Node->getOpcode() == ISD::ADD) {
> + Lo = DAG.getNode(ISD::ADDC, VTList, LoOps, 2);
> + HiOps[2] = Lo.getValue(1);
> + Hi = DAG.getNode(ISD::ADDE, VTList, HiOps, 3);
> + } else {
> + Lo = DAG.getNode(ISD::SUBC, VTList, LoOps, 2);
> + HiOps[2] = Lo.getValue(1);
> + Hi = DAG.getNode(ISD::SUBE, VTList, HiOps, 3);
> + }
> + break;
> } else {
> - Lo = DAG.getNode(ISD::SUBC, VTList, LoOps, 2);
> - HiOps[2] = Lo.getValue(1);
> - Hi = DAG.getNode(ISD::SUBE, VTList, HiOps, 3);
> + if (Node->getOpcode() == ISD::ADD) {
> + Lo = DAG.getNode(ISD::ADD, VTList, LoOps, 2);
> + Hi = DAG.getNode(ISD::ADD, VTList, HiOps, 2);
> + SDValue Cmp1 = DAG.getSetCC(NVT, Lo, LoOps[0], ISD::SETULT);
> + SDValue Carry1 = DAG.getNode(ISD::SELECT, NVT, Cmp1,
> + DAG.getConstant(1, NVT),
> + DAG.getConstant(0, NVT));
> + SDValue Cmp2 = DAG.getSetCC(NVT, Lo, LoOps[1], ISD::SETULT);
> + SDValue Carry2 = DAG.getNode(ISD::SELECT, NVT, Cmp2,
> + DAG.getConstant(1, NVT),
> + Carry1);
> + Hi = DAG.getNode(ISD::ADD, NVT, Hi, Carry2);
> + } else {
> + Lo = DAG.getNode(ISD::SUB, VTList, LoOps, 2);
> + Hi = DAG.getNode(ISD::SUB, VTList, HiOps, 2);
> + SDValue Cmp = DAG.getSetCC(NVT, LoOps[0], LoOps[1], ISD::SETULT);
> + SDValue Borrow = DAG.getNode(ISD::SELECT, NVT, Cmp,
> + DAG.getConstant(1, NVT),
> + DAG.getConstant(0, NVT));
> + Hi = DAG.getNode(ISD::SUB, NVT, Hi, Borrow);
> + }
> + break;
> }
> - break;
> }
>
> case ISD::ADDC:
>
> Modified: llvm/trunk/test/CodeGen/Alpha/add128.ll
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Alpha/add128.ll?rev=57243&r1=57242&r2=57243&view=diff
>
> ==============================================================================
> --- llvm/trunk/test/CodeGen/Alpha/add128.ll (original)
> +++ llvm/trunk/test/CodeGen/Alpha/add128.ll Tue Oct 7 09:15:42 2008
> @@ -1,7 +1,6 @@
> ;test for ADDC and ADDE expansion
> ;
> ; RUN: llvm-as < %s | llc -march=alpha
> -; XFAIL: *
>
> define i128 @add128(i128 %x, i128 %y) {
> entry:
>
> Added: llvm/trunk/test/CodeGen/Alpha/sub128.ll
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Alpha/sub128.ll?rev=57243&view=auto
>
> ==============================================================================
> --- llvm/trunk/test/CodeGen/Alpha/sub128.ll (added)
> +++ llvm/trunk/test/CodeGen/Alpha/sub128.ll Tue Oct 7 09:15:42 2008
> @@ -0,0 +1,9 @@
> +;test for SUBC and SUBE expansion
> +;
> +; RUN: llvm-as < %s | llc -march=alpha
> +
> +define i128 @sub128(i128 %x, i128 %y) {
> +entry:
> + %tmp = sub i128 %y, %x
> + ret i128 %tmp
> +}
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
From alenhar2 at cs.uiuc.edu Tue Oct 7 12:03:16 2008
From: alenhar2 at cs.uiuc.edu (Andrew Lenharth)
Date: Tue, 07 Oct 2008 17:03:16 -0000
Subject: [llvm-commits] [llvm] r57247 -
/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
Message-ID: <200810071703.m97H3GGL002647@zion.cs.uiuc.edu>
Author: alenhar2
Date: Tue Oct 7 12:03:15 2008
New Revision: 57247
URL: http://llvm.org/viewvc/llvm-project?rev=57247&view=rev
Log:
Use ADDC if it is valid at any smaller size. fixes test/Codegen/Generic/i128-addsub.ll on x86
Modified:
llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp?rev=57247&r1=57246&r2=57247&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp Tue Oct 7 12:03:15 2008
@@ -6441,7 +6441,20 @@
LoOps[1] = RHSL;
HiOps[0] = LHSH;
HiOps[1] = RHSH;
- if(TLI.isOperationLegal(ISD::ADDC, NVT)) {
+ //cascaded check to see if any smaller size has a a carry flag.
+ unsigned OpV = Node->getOpcode() == ISD::ADD ? ISD::ADDC : ISD::SUBC;
+ bool hasCarry = false;
+ if (NVT == MVT::i64)
+ hasCarry |= TLI.isOperationLegal(OpV, MVT::i32)
+ | TLI.isOperationLegal(OpV, MVT::i16)
+ | TLI.isOperationLegal(OpV, MVT::i8);
+ if (NVT == MVT::i32)
+ hasCarry |= TLI.isOperationLegal(OpV, MVT::i16)
+ | TLI.isOperationLegal(OpV, MVT::i8);
+ if (NVT == MVT::i16)
+ hasCarry |= TLI.isOperationLegal(OpV, MVT::i8);
+
+ if(hasCarry) {
if (Node->getOpcode() == ISD::ADD) {
Lo = DAG.getNode(ISD::ADDC, VTList, LoOps, 2);
HiOps[2] = Lo.getValue(1);
@@ -6456,11 +6469,13 @@
if (Node->getOpcode() == ISD::ADD) {
Lo = DAG.getNode(ISD::ADD, VTList, LoOps, 2);
Hi = DAG.getNode(ISD::ADD, VTList, HiOps, 2);
- SDValue Cmp1 = DAG.getSetCC(NVT, Lo, LoOps[0], ISD::SETULT);
+ SDValue Cmp1 = DAG.getSetCC(TLI.getSetCCResultType(Lo),
+ Lo, LoOps[0], ISD::SETULT);
SDValue Carry1 = DAG.getNode(ISD::SELECT, NVT, Cmp1,
DAG.getConstant(1, NVT),
DAG.getConstant(0, NVT));
- SDValue Cmp2 = DAG.getSetCC(NVT, Lo, LoOps[1], ISD::SETULT);
+ SDValue Cmp2 = DAG.getSetCC(TLI.getSetCCResultType(Lo),
+ Lo, LoOps[1], ISD::SETULT);
SDValue Carry2 = DAG.getNode(ISD::SELECT, NVT, Cmp2,
DAG.getConstant(1, NVT),
Carry1);
From alenhar2 at cs.uiuc.edu Tue Oct 7 12:09:16 2008
From: alenhar2 at cs.uiuc.edu (Andrew Lenharth)
Date: Tue, 07 Oct 2008 17:09:16 -0000
Subject: [llvm-commits] [llvm] r57248 -
/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
Message-ID: <200810071709.m97H9Hsd002878@zion.cs.uiuc.edu>
Author: alenhar2
Date: Tue Oct 7 12:09:16 2008
New Revision: 57248
URL: http://llvm.org/viewvc/llvm-project?rev=57248&view=rev
Log:
Use ADDC if it is valid at any smaller size. Do it right this time
Modified:
llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp?rev=57248&r1=57247&r2=57248&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp Tue Oct 7 12:09:16 2008
@@ -6445,14 +6445,17 @@
unsigned OpV = Node->getOpcode() == ISD::ADD ? ISD::ADDC : ISD::SUBC;
bool hasCarry = false;
if (NVT == MVT::i64)
- hasCarry |= TLI.isOperationLegal(OpV, MVT::i32)
+ hasCarry |= TLI.isOperationLegal(OpV, MVT::i64)
+ | TLI.isOperationLegal(OpV, MVT::i32)
| TLI.isOperationLegal(OpV, MVT::i16)
| TLI.isOperationLegal(OpV, MVT::i8);
if (NVT == MVT::i32)
- hasCarry |= TLI.isOperationLegal(OpV, MVT::i16)
+ hasCarry |= TLI.isOperationLegal(OpV, MVT::i32)
+ | TLI.isOperationLegal(OpV, MVT::i16)
| TLI.isOperationLegal(OpV, MVT::i8);
if (NVT == MVT::i16)
- hasCarry |= TLI.isOperationLegal(OpV, MVT::i8);
+ hasCarry |= TLI.isOperationLegal(OpV, MVT::i16)
+ | TLI.isOperationLegal(OpV, MVT::i8);
if(hasCarry) {
if (Node->getOpcode() == ISD::ADD) {
From alenhar2 at cs.uiuc.edu Tue Oct 7 12:11:29 2008
From: alenhar2 at cs.uiuc.edu (Andrew Lenharth)
Date: Tue, 07 Oct 2008 17:11:29 -0000
Subject: [llvm-commits] [llvm] r57249 -
/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
Message-ID: <200810071711.m97HBTfF002956@zion.cs.uiuc.edu>
Author: alenhar2
Date: Tue Oct 7 12:11:29 2008
New Revision: 57249
URL: http://llvm.org/viewvc/llvm-project?rev=57249&view=rev
Log:
No need for |=
Modified:
llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp?rev=57249&r1=57248&r2=57249&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp Tue Oct 7 12:11:29 2008
@@ -6445,16 +6445,16 @@
unsigned OpV = Node->getOpcode() == ISD::ADD ? ISD::ADDC : ISD::SUBC;
bool hasCarry = false;
if (NVT == MVT::i64)
- hasCarry |= TLI.isOperationLegal(OpV, MVT::i64)
+ hasCarry = TLI.isOperationLegal(OpV, MVT::i64)
| TLI.isOperationLegal(OpV, MVT::i32)
| TLI.isOperationLegal(OpV, MVT::i16)
| TLI.isOperationLegal(OpV, MVT::i8);
if (NVT == MVT::i32)
- hasCarry |= TLI.isOperationLegal(OpV, MVT::i32)
+ hasCarry = TLI.isOperationLegal(OpV, MVT::i32)
| TLI.isOperationLegal(OpV, MVT::i16)
| TLI.isOperationLegal(OpV, MVT::i8);
if (NVT == MVT::i16)
- hasCarry |= TLI.isOperationLegal(OpV, MVT::i16)
+ hasCarry = TLI.isOperationLegal(OpV, MVT::i16)
| TLI.isOperationLegal(OpV, MVT::i8);
if(hasCarry) {
From alenhar2 at cs.uiuc.edu Tue Oct 7 12:13:32 2008
From: alenhar2 at cs.uiuc.edu (Andrew Lenharth)
Date: Tue, 07 Oct 2008 17:13:32 -0000
Subject: [llvm-commits] [llvm] r57250 -
/llvm/trunk/test/CodeGen/Alpha/mul128.ll
Message-ID: <200810071713.m97HDWGa003016@zion.cs.uiuc.edu>
Author: alenhar2
Date: Tue Oct 7 12:13:32 2008
New Revision: 57250
URL: http://llvm.org/viewvc/llvm-project?rev=57250&view=rev
Log:
128 mul test, xfailed
Added:
llvm/trunk/test/CodeGen/Alpha/mul128.ll
Added: llvm/trunk/test/CodeGen/Alpha/mul128.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Alpha/mul128.ll?rev=57250&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/Alpha/mul128.ll (added)
+++ llvm/trunk/test/CodeGen/Alpha/mul128.ll Tue Oct 7 12:13:32 2008
@@ -0,0 +1,8 @@
+; RUN: llvm-as < %s | llc -march=alpha
+; XFAIL: *
+
+define i128 @__mulvdi3(i128 %a, i128 %b) nounwind {
+entry:
+ %r = mul i128 %a, %b
+ ret i128 %r
+}
From andrewl at lenharth.org Tue Oct 7 12:20:13 2008
From: andrewl at lenharth.org (Andrew Lenharth)
Date: Tue, 7 Oct 2008 12:20:13 -0500
Subject: [llvm-commits] PR2765 Patch
Message-ID: <85dfcd7f0810071020w4a0cf3b7vb3fc21e90867c346@mail.gmail.com>
The following is a patch for
http://llvm.org/bugs/show_bug.cgi?id=2765
It shouldn't change the behavior in the common case (pure cloning) but
does the correct thing when removing arguments durring clone. Passes
all tests. Ok to commit?
Andrew
Index: lib/Transforms/Utils/CloneFunction.cpp
===================================================================
--- lib/Transforms/Utils/CloneFunction.cpp (revision 57242)
+++ lib/Transforms/Utils/CloneFunction.cpp (working copy)
@@ -81,8 +81,24 @@
#endif
// Clone any attributes.
- NewFunc->copyAttributesFrom(OldFunc);
+ if (NewFunc->arg_size() == OldFunc->arg_size())
+ NewFunc->copyAttributesFrom(OldFunc);
+ else {
+ //Some arguments were deleted with the ValueMap. Copy arguments one by one
+ for (Function::const_arg_iterator I = OldFunc->arg_begin(),
+ E = OldFunc->arg_end(); I != E; ++I)
+ if (Argument* Anew = dyn_cast(ValueMap[I]))
+ Anew->addAttr( OldFunc->getAttributes()
+ .getParamAttributes(I->getArgNo() + 1));
+ NewFunc->setAttributes(NewFunc->getAttributes()
+ .addAttr(0, OldFunc->getAttributes()
+ .getRetAttributes()));
+ NewFunc->setAttributes(NewFunc->getAttributes()
+ .addAttr(~0, OldFunc->getAttributes()
+ .getFnAttributes()));
+ }
+
// Loop over all of the basic blocks in the function, cloning them as
// appropriate. Note that we save BE this way in order to handle cloning of
// recursive functions into themselves.
From grosbach at apple.com Tue Oct 7 12:40:46 2008
From: grosbach at apple.com (Jim Grosbach)
Date: Tue, 07 Oct 2008 17:40:46 -0000
Subject: [llvm-commits] [llvm] r57251 -
/llvm/trunk/lib/Target/ARM/ARMInstrInfo.td
Message-ID: <200810071740.m97HekQJ003849@zion.cs.uiuc.edu>
Author: grosbach
Date: Tue Oct 7 12:40:46 2008
New Revision: 57251
URL: http://llvm.org/viewvc/llvm-project?rev=57251&view=rev
Log:
Fix Opcode values of CMP and CMN
Modified:
llvm/trunk/lib/Target/ARM/ARMInstrInfo.td
Modified: llvm/trunk/lib/Target/ARM/ARMInstrInfo.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMInstrInfo.td?rev=57251&r1=57250&r2=57251&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMInstrInfo.td (original)
+++ llvm/trunk/lib/Target/ARM/ARMInstrInfo.td Tue Oct 7 12:40:46 2008
@@ -1099,9 +1099,9 @@
// Comparison Instructions...
//
-defm CMP : AI1_cmp_irs<0xA, "cmp",
+defm CMP : AI1_cmp_irs<{0,1,0,1}, "cmp",
BinOpFrag<(ARMcmp node:$LHS, node:$RHS)>>;
-defm CMN : AI1_cmp_irs<0xB, "cmn",
+defm CMN : AI1_cmp_irs<{1,1,0,1}, "cmn",
BinOpFrag<(ARMcmp node:$LHS,(ineg node:$RHS))>>;
// Note that TST/TEQ don't set all the same flags that CMP does!
@@ -1110,9 +1110,9 @@
defm TEQ : AI1_cmp_irs<0x9, "teq",
BinOpFrag<(ARMcmpNZ (xor node:$LHS, node:$RHS), 0)>>;
-defm CMPnz : AI1_cmp_irs<0xA, "cmp",
+defm CMPnz : AI1_cmp_irs<{0,1,0,1}, "cmp",
BinOpFrag<(ARMcmpNZ node:$LHS, node:$RHS)>>;
-defm CMNnz : AI1_cmp_irs<0xA, "cmn",
+defm CMNnz : AI1_cmp_irs<{1,1,0,1}, "cmn",
BinOpFrag<(ARMcmpNZ node:$LHS,(ineg node:$RHS))>>;
def : ARMPat<(ARMcmp GPR:$src, so_imm_neg:$imm),
From dalej at apple.com Tue Oct 7 12:41:35 2008
From: dalej at apple.com (Dale Johannesen)
Date: Tue, 7 Oct 2008 10:41:35 -0700
Subject: [llvm-commits] [llvm]
r57185 - /llvm/trunk/lib/Support/APFloat.cpp
In-Reply-To: <20081007131921.GF19669@daikokuya.co.uk>
References: <200810061822.m96IMTgD007250@zion.cs.uiuc.edu>
<0C450614-92AA-4337-B0EA-53797DA53326@apple.com>
<20081007131921.GF19669@daikokuya.co.uk>
Message-ID: <3D552C79-1370-4B36-8A6B-7CEE082AE4DC@apple.com>
On Oct 7, 2008, at 6:19 AMPDT, Neil Booth wrote:
> Dale Johannesen wrote:-
>> To confuse things further, the value in the PR is not even an IEEE
>> NaN, but a pseudo-NaN in Intel jargon. It is outside all standards.
>
> The intent of APFloat as I wrote it was to replicate a conforming
> IEEE-754 CPU's results in software, with the return result indicating
> those exceptions that would occur under IEEE-754. IBM double double
> was later hacked on in an incomplete way.
>
> The paragraph you quote is unambiguous; these NaN to NaN conversions
> should always return fsOK because it "shall signal no exception".
> This is how the code worked before your change.
>
> Perhaps LLVM needs APFloat to evolve beyond IEEE-754; I'm not sure.
> But I suggest you think hard about that, and if you decide to go that
> way you at least use a new flag for your extensions. You should
> also update the comments in the .cpp and .h files appropriately,
> and review what other changes, if any, to other operations are needed
> to accomdate your new semantics.
Good to hear from you on this one.
What the rest of the compiler wants to know is whether a conversion
can be done without loss of information. I.e. if you convert type A
to type B, then back to type A, you get the original value. Right now
it's using the return value == fsOK check
to figure that out. I suppose the various call sites could be taught
about NaNs but it really seems better to keep those details buried in
APFloat somehow.
I guess we could add a separate "conversion doesn't lose information"
return value to the conversion routines, or even convert back and
compare at the call sites, although that seems silly when the first
conversion has all the needed information. I'm not so sure it's worth
preserving strict IEEE behavior in all these edge cases, though,
what's the value of that in LLVM? How would you approach the problem?
When I implemented the -0.0 conversion to int, I thought that was what
IEEE754 calls for, but I missed the definition of inexact, obscurely
placed in 7.4(4). 6.3 is clear that the result should have a negative
sign, and that's not implementable on a twos complement machine, yet
none of the exceptions seems to apply; I guess the standard calls for
quietly producing an answer known to be wrong. This one really seems
like a bug in the standard.
From grosbach at apple.com Tue Oct 7 12:42:10 2008
From: grosbach at apple.com (Jim Grosbach)
Date: Tue, 07 Oct 2008 17:42:10 -0000
Subject: [llvm-commits] [llvm] r57252 -
/llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp
Message-ID: <200810071742.m97HgAYm003906@zion.cs.uiuc.edu>
Author: grosbach
Date: Tue Oct 7 12:42:09 2008
New Revision: 57252
URL: http://llvm.org/viewvc/llvm-project?rev=57252&view=rev
Log:
Clarify naming and correct conditional so that CMP and CMN instructions get the Rn operand encoded properly
Modified:
llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp
Modified: llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp?rev=57252&r1=57251&r2=57252&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp (original)
+++ llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp Tue Oct 7 12:42:09 2008
@@ -392,14 +392,11 @@
// Encode first non-shifter register operand if there is one.
unsigned Format = TID.TSFlags & ARMII::FormMask;
- bool isUnary = (Format == ARMII::DPRdMisc ||
- Format == ARMII::DPRdIm ||
- Format == ARMII::DPRdReg ||
- Format == ARMII::DPRdSoReg ||
- Format == ARMII::DPRnIm ||
- Format == ARMII::DPRnReg ||
- Format == ARMII::DPRnSoReg);
- if (!isUnary) {
+ bool hasRnOperand= !(Format == ARMII::DPRdMisc ||
+ Format == ARMII::DPRdIm ||
+ Format == ARMII::DPRdReg ||
+ Format == ARMII::DPRdSoReg);
+ if (hasRnOperand) {
Binary |= getMachineOpValue(MI, OpIdx) << ARMII::RegRnShift;
++OpIdx;
}
From dpatel at apple.com Tue Oct 7 12:48:33 2008
From: dpatel at apple.com (Devang Patel)
Date: Tue, 07 Oct 2008 17:48:33 -0000
Subject: [llvm-commits] [llvm] r57253 - /llvm/trunk/docs/LangRef.html
Message-ID: <200810071748.m97HmXRo004122@zion.cs.uiuc.edu>
Author: dpatel
Date: Tue Oct 7 12:48:33 2008
New Revision: 57253
URL: http://llvm.org/viewvc/llvm-project?rev=57253&view=rev
Log:
Improve function definition, call and invoke instruction docs.
Modified:
llvm/trunk/docs/LangRef.html
Modified: llvm/trunk/docs/LangRef.html
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/LangRef.html?rev=57253&r1=57252&r2=57253&view=diff
==============================================================================
--- llvm/trunk/docs/LangRef.html (original)
+++ llvm/trunk/docs/LangRef.html Tue Oct 7 12:48:33 2008
@@ -784,6 +784,14 @@
function is forced to have at least that much alignment. All alignments must be
a power of 2.
+ Syntax:
+
+
+
@@ -2046,8 +2054,7 @@
Syntax:
- <result> = invoke [cconv] [RetAttrs] <ptr to function ty> <function ptr val>(<function args>)
+ <result> = invoke [cconv] [ret attrs] <ptr to function ty> <function ptr val>(<function args>) [fn attrs]
to label <normal label> unwind label <exception label>
@@ -2097,7 +2104,7 @@
'exception label': the label reached when a callee returns with
the unwind instruction.
- The optional function attributes list. Only
+ The optional function attributes list. Only
'noreturn', 'nounwind', 'readonly' and
'readnone' attributes are valid here.
@@ -4249,7 +4256,7 @@
Syntax:
- <result> = [tail] call [cconv] [RetAttrs] <ty> [<fnty>*] <fnptrval>(<param list>)
+ <result> = [tail] call [cconv] [ret attrs] <ty> [<fnty>*] <fnptrval>(<function args>) [fn attrs]
Overview:
@@ -4305,7 +4312,7 @@
arguments can be specified.
- The optional function attributes list. Only
+
The optional function attributes list. Only
'noreturn', 'nounwind', 'readonly' and
'readnone' attributes are valid here.
From gohman at apple.com Tue Oct 7 12:53:57 2008
From: gohman at apple.com (Dan Gohman)
Date: Tue, 7 Oct 2008 10:53:57 -0700 (PDT)
Subject: [llvm-commits] [llvm] r57247 -
/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
In-Reply-To: <200810071703.m97H3GGL002647@zion.cs.uiuc.edu>
References: <200810071703.m97H3GGL002647@zion.cs.uiuc.edu>
Message-ID: <54924.76.220.41.203.1223402037.squirrel@webmail.apple.com>
On Tue, October 7, 2008 10:03 am, Andrew Lenharth wrote:
> Author: alenhar2
> Date: Tue Oct 7 12:03:15 2008
> New Revision: 57247
>
> URL: http://llvm.org/viewvc/llvm-project?rev=57247&view=rev
> Log:
> Use ADDC if it is valid at any smaller size. fixes
> test/Codegen/Generic/i128-addsub.ll on x86
>
> Modified:
> llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
>
> Modified: llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
> URL:
> http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp?rev=57247&r1=57246&r2=57247&view=diff
>
> ==============================================================================
> --- llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp (original)
> +++ llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp Tue Oct 7
> 12:03:15 2008
> @@ -6441,7 +6441,20 @@
> LoOps[1] = RHSL;
> HiOps[0] = LHSH;
> HiOps[1] = RHSH;
> - if(TLI.isOperationLegal(ISD::ADDC, NVT)) {
> + //cascaded check to see if any smaller size has a a carry flag.
> + unsigned OpV = Node->getOpcode() == ISD::ADD ? ISD::ADDC : ISD::SUBC;
> + bool hasCarry = false;
> + if (NVT == MVT::i64)
> + hasCarry |= TLI.isOperationLegal(OpV, MVT::i32)
> + | TLI.isOperationLegal(OpV, MVT::i16)
> + | TLI.isOperationLegal(OpV, MVT::i8);
> + if (NVT == MVT::i32)
> + hasCarry |= TLI.isOperationLegal(OpV, MVT::i16)
> + | TLI.isOperationLegal(OpV, MVT::i8);
> + if (NVT == MVT::i16)
> + hasCarry |= TLI.isOperationLegal(OpV, MVT::i8);
Previously, it was possible to do an i256 add on x86. I guess we
don't have any testcases for that in the repository though.
How about a more general approach? Warning untested code:
bool hasCarry = false;
for (unsigned BitSize = NVT.getSizeInBits(); BitSize != 0; BitSize /= 2) {
MVT AVT = MVT::getIntegerVT(BitSize);
if (TLI.isOperationLegal(OpV, AVT)) {
hasCarry = true;
break;
}
}
FWIW, LegalizeIntegerTypes.cpp will eventually need to do
something similar, and it'll need to account for non-power-of-two
integer sizes also.
Dan
From dpatel at apple.com Tue Oct 7 13:00:04 2008
From: dpatel at apple.com (Devang Patel)
Date: Tue, 7 Oct 2008 11:00:04 -0700
Subject: [llvm-commits] PR2765 Patch
In-Reply-To: <85dfcd7f0810071020w4a0cf3b7vb3fc21e90867c346@mail.gmail.com>
References: <85dfcd7f0810071020w4a0cf3b7vb3fc21e90867c346@mail.gmail.com>
Message-ID: <6E453EE6-194B-4783-88D1-2F39497326F4@apple.com>
On Oct 7, 2008, at 10:20 AM, Andrew Lenharth wrote:
> The following is a patch for
> http://llvm.org/bugs/show_bug.cgi?id=2765
>
> It shouldn't change the behavior in the common case (pure cloning) but
> does the correct thing when removing arguments durring clone. Passes
> all tests. Ok to commit?
yes, looks good.
>
>
> Andrew
>
> Index: lib/Transforms/Utils/CloneFunction.cpp
> ===================================================================
> --- lib/Transforms/Utils/CloneFunction.cpp (revision 57242)
> +++ lib/Transforms/Utils/CloneFunction.cpp (working copy)
> @@ -81,8 +81,24 @@
> #endif
>
> // Clone any attributes.
> - NewFunc->copyAttributesFrom(OldFunc);
> + if (NewFunc->arg_size() == OldFunc->arg_size())
> + NewFunc->copyAttributesFrom(OldFunc);
> + else {
> + //Some arguments were deleted with the ValueMap. Copy arguments
> one by one
> + for (Function::const_arg_iterator I = OldFunc->arg_begin(),
> + E = OldFunc->arg_end(); I != E; ++I)
> + if (Argument* Anew = dyn_cast(ValueMap[I]))
> + Anew->addAttr( OldFunc->getAttributes()
> + .getParamAttributes(I->getArgNo() + 1));
> + NewFunc->setAttributes(NewFunc->getAttributes()
> + .addAttr(0, OldFunc->getAttributes()
> + .getRetAttributes()));
> + NewFunc->setAttributes(NewFunc->getAttributes()
> + .addAttr(~0, OldFunc->getAttributes()
> + .getFnAttributes()));
>
> + }
> +
> // Loop over all of the basic blocks in the function, cloning them
> as
> // appropriate. Note that we save BE this way in order to handle
> cloning of
> // recursive functions into themselves.
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
-
Devang
From alenhar2 at cs.uiuc.edu Tue Oct 7 13:08:39 2008
From: alenhar2 at cs.uiuc.edu (Andrew Lenharth)
Date: Tue, 07 Oct 2008 18:08:39 -0000
Subject: [llvm-commits] [llvm] r57254 -
/llvm/trunk/lib/Transforms/Utils/CloneFunction.cpp
Message-ID: <200810071808.m97I8dCV004839@zion.cs.uiuc.edu>
Author: alenhar2
Date: Tue Oct 7 13:08:38 2008
New Revision: 57254
URL: http://llvm.org/viewvc/llvm-project?rev=57254&view=rev
Log:
Correctly set attributes when removing args during cloning. Fixes PR2765
Modified:
llvm/trunk/lib/Transforms/Utils/CloneFunction.cpp
Modified: llvm/trunk/lib/Transforms/Utils/CloneFunction.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Utils/CloneFunction.cpp?rev=57254&r1=57253&r2=57254&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Utils/CloneFunction.cpp (original)
+++ llvm/trunk/lib/Transforms/Utils/CloneFunction.cpp Tue Oct 7 13:08:38 2008
@@ -81,7 +81,23 @@
#endif
// Clone any attributes.
- NewFunc->copyAttributesFrom(OldFunc);
+ if (NewFunc->arg_size() == OldFunc->arg_size())
+ NewFunc->copyAttributesFrom(OldFunc);
+ else {
+ //Some arguments were deleted with the ValueMap. Copy arguments one by one
+ for (Function::const_arg_iterator I = OldFunc->arg_begin(),
+ E = OldFunc->arg_end(); I != E; ++I)
+ if (Argument* Anew = dyn_cast(ValueMap[I]))
+ Anew->addAttr( OldFunc->getAttributes()
+ .getParamAttributes(I->getArgNo() + 1));
+ NewFunc->setAttributes(NewFunc->getAttributes()
+ .addAttr(0, OldFunc->getAttributes()
+ .getRetAttributes()));
+ NewFunc->setAttributes(NewFunc->getAttributes()
+ .addAttr(~0, OldFunc->getAttributes()
+ .getFnAttributes()));
+
+ }
// Loop over all of the basic blocks in the function, cloning them as
// appropriate. Note that we save BE this way in order to handle cloning of
From alenhar2 at cs.uiuc.edu Tue Oct 7 13:27:23 2008
From: alenhar2 at cs.uiuc.edu (Andrew Lenharth)
Date: Tue, 07 Oct 2008 18:27:23 -0000
Subject: [llvm-commits] [llvm] r57255 -
/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
Message-ID: <200810071827.m97IRNes005514@zion.cs.uiuc.edu>
Author: alenhar2
Date: Tue Oct 7 13:27:23 2008
New Revision: 57255
URL: http://llvm.org/viewvc/llvm-project?rev=57255&view=rev
Log:
Use Dan's supperior check
Modified:
llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp?rev=57255&r1=57254&r2=57255&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp Tue Oct 7 13:27:23 2008
@@ -6441,22 +6441,18 @@
LoOps[1] = RHSL;
HiOps[0] = LHSH;
HiOps[1] = RHSH;
+
//cascaded check to see if any smaller size has a a carry flag.
unsigned OpV = Node->getOpcode() == ISD::ADD ? ISD::ADDC : ISD::SUBC;
bool hasCarry = false;
- if (NVT == MVT::i64)
- hasCarry = TLI.isOperationLegal(OpV, MVT::i64)
- | TLI.isOperationLegal(OpV, MVT::i32)
- | TLI.isOperationLegal(OpV, MVT::i16)
- | TLI.isOperationLegal(OpV, MVT::i8);
- if (NVT == MVT::i32)
- hasCarry = TLI.isOperationLegal(OpV, MVT::i32)
- | TLI.isOperationLegal(OpV, MVT::i16)
- | TLI.isOperationLegal(OpV, MVT::i8);
- if (NVT == MVT::i16)
- hasCarry = TLI.isOperationLegal(OpV, MVT::i16)
- | TLI.isOperationLegal(OpV, MVT::i8);
-
+ for (unsigned BitSize = NVT.getSizeInBits(); BitSize != 0; BitSize /= 2) {
+ MVT AVT = MVT::getIntegerVT(BitSize);
+ if (TLI.isOperationLegal(OpV, AVT)) {
+ hasCarry = true;
+ break;
+ }
+ }
+
if(hasCarry) {
if (Node->getOpcode() == ISD::ADD) {
Lo = DAG.getNode(ISD::ADDC, VTList, LoOps, 2);
From andrewl at lenharth.org Tue Oct 7 13:27:47 2008
From: andrewl at lenharth.org (Andrew Lenharth)
Date: Tue, 7 Oct 2008 13:27:47 -0500
Subject: [llvm-commits] [llvm] r57247 -
/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
In-Reply-To: <54924.76.220.41.203.1223402037.squirrel@webmail.apple.com>
References: <200810071703.m97H3GGL002647@zion.cs.uiuc.edu>
<54924.76.220.41.203.1223402037.squirrel@webmail.apple.com>
Message-ID: <85dfcd7f0810071127t5fb067b9g44de8be2973703d7@mail.gmail.com>
On Tue, Oct 7, 2008 at 12:53 PM, Dan Gohman wrote:
> Previously, it was possible to do an i256 add on x86. I guess we
> don't have any testcases for that in the repository though.
> How about a more general approach? Warning untested code:
>
> bool hasCarry = false;
> for (unsigned BitSize = NVT.getSizeInBits(); BitSize != 0; BitSize /= 2) {
> MVT AVT = MVT::getIntegerVT(BitSize);
> if (TLI.isOperationLegal(OpV, AVT)) {
> hasCarry = true;
> break;
> }
> }
Yes, much better. And now tested.
Andrew
From evan.cheng at apple.com Tue Oct 7 13:44:14 2008
From: evan.cheng at apple.com (Evan Cheng)
Date: Tue, 07 Oct 2008 18:44:14 -0000
Subject: [llvm-commits] [llvm-gcc-4.2] r57256 -
/llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
Message-ID: <200810071844.m97IiEk2006076@zion.cs.uiuc.edu>
Author: evancheng
Date: Tue Oct 7 13:44:13 2008
New Revision: 57256
URL: http://llvm.org/viewvc/llvm-project?rev=57256&view=rev
Log:
Per Duncan's review: eh_select expressions do not need bitcast.
Modified:
llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
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=57256&r1=57255&r2=57256&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp (original)
+++ llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp Tue Oct 7 13:44:13 2008
@@ -3747,9 +3747,7 @@
Value *TreeToLLVM::EmitFILTER_EXPR(tree exp) {
CreateExceptionValues();
// Load exception selector.
- Value *V = Builder.CreateLoad(ExceptionSelectorValue, "eh_select");
- // Cast the address to the right pointer type.
- return BitCastToType(V, ConvertType(TREE_TYPE(exp)));
+ return Builder.CreateLoad(ExceptionSelectorValue, "eh_select");
}
/// EmitRESX_EXPR - Handle RESX_EXPR.
@@ -6190,8 +6188,7 @@
LValue TreeToLLVM::EmitLV_FILTER_EXPR(tree exp) {
CreateExceptionValues();
- return BitCastToType(ExceptionSelectorValue,
- PointerType::getUnqual(ConvertType(TREE_TYPE(exp))));
+ return ExceptionSelectorValue;
}
//===----------------------------------------------------------------------===//
From dalej at apple.com Tue Oct 7 13:54:29 2008
From: dalej at apple.com (Dale Johannesen)
Date: Tue, 07 Oct 2008 18:54:29 -0000
Subject: [llvm-commits] [llvm] r57257 -
/llvm/trunk/lib/Target/X86/X86InstrInfo.td
Message-ID: <200810071854.m97IsTFq006416@zion.cs.uiuc.edu>
Author: johannes
Date: Tue Oct 7 13:54:28 2008
New Revision: 57257
URL: http://llvm.org/viewvc/llvm-project?rev=57257&view=rev
Log:
Model hardwired inputs & outputs of x86 8-bit divides correctly.
Fixes local RA miscompilation of gcc.c-torture/execute/20020904-1.c -O0.
Modified:
llvm/trunk/lib/Target/X86/X86InstrInfo.td
Modified: llvm/trunk/lib/Target/X86/X86InstrInfo.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrInfo.td?rev=57257&r1=57256&r2=57257&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86InstrInfo.td (original)
+++ llvm/trunk/lib/Target/X86/X86InstrInfo.td Tue Oct 7 13:54:28 2008
@@ -728,7 +728,7 @@
}
// unsigned division/remainder
-let Defs = [AX,EFLAGS], Uses = [AL,AH] in
+let Defs = [AL,AH,EFLAGS], Uses = [AX] in
def DIV8r : I<0xF6, MRM6r, (outs), (ins GR8:$src), // AX/r8 = AL,AH
"div{b}\t$src", []>;
let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
@@ -738,7 +738,7 @@
def DIV32r : I<0xF7, MRM6r, (outs), (ins GR32:$src), // EDX:EAX/r32 = EAX,EDX
"div{l}\t$src", []>;
let mayLoad = 1 in {
-let Defs = [AX,EFLAGS], Uses = [AL,AH] in
+let Defs = [AL,AH,EFLAGS], Uses = [AX] in
def DIV8m : I<0xF6, MRM6m, (outs), (ins i8mem:$src), // AX/[mem8] = AL,AH
"div{b}\t$src", []>;
let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
@@ -750,7 +750,7 @@
}
// Signed division/remainder.
-let Defs = [AX,EFLAGS], Uses = [AL,AH] in
+let Defs = [AL,AH,EFLAGS], Uses = [AX] in
def IDIV8r : I<0xF6, MRM7r, (outs), (ins GR8:$src), // AX/r8 = AL,AH
"idiv{b}\t$src", []>;
let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
@@ -760,7 +760,7 @@
def IDIV32r: I<0xF7, MRM7r, (outs), (ins GR32:$src), // EDX:EAX/r32 = EAX,EDX
"idiv{l}\t$src", []>;
let mayLoad = 1, mayLoad = 1 in {
-let Defs = [AX,EFLAGS], Uses = [AL,AH] in
+let Defs = [AL,AH,EFLAGS], Uses = [AX] in
def IDIV8m : I<0xF6, MRM7m, (outs), (ins i8mem:$src), // AX/[mem8] = AL,AH
"idiv{b}\t$src", []>;
let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
From grosbach at apple.com Tue Oct 7 14:05:35 2008
From: grosbach at apple.com (Jim Grosbach)
Date: Tue, 07 Oct 2008 19:05:35 -0000
Subject: [llvm-commits] [llvm] r57258 - in /llvm/trunk/lib/Target/ARM:
ARMCodeEmitter.cpp ARMInstrInfo.h
Message-ID: <200810071905.m97J5aEk006788@zion.cs.uiuc.edu>
Author: grosbach
Date: Tue Oct 7 14:05:35 2008
New Revision: 57258
URL: http://llvm.org/viewvc/llvm-project?rev=57258&view=rev
Log:
Encode the conditional execution predicate when JITing.
Modified:
llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp
llvm/trunk/lib/Target/ARM/ARMInstrInfo.h
Modified: llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp?rev=57258&r1=57257&r2=57258&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp (original)
+++ llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp Tue Oct 7 14:05:35 2008
@@ -256,8 +256,8 @@
unsigned ARMCodeEmitter::getAddrModeNoneInstrBinary(const MachineInstr &MI,
const TargetInstrDesc &TID,
unsigned Binary) {
- // FIXME: Assume CC is AL for now.
- Binary |= ARMCC::AL << 28;
+ // Set the conditional execution predicate
+ Binary |= II->getPredicate(&MI) << 28;
switch (TID.TSFlags & ARMII::FormMask) {
default:
@@ -376,8 +376,8 @@
unsigned ARMCodeEmitter::getAddrMode1InstrBinary(const MachineInstr &MI,
const TargetInstrDesc &TID,
unsigned Binary) {
- // FIXME: Assume CC is AL for now.
- Binary |= ARMCC::AL << 28;
+ // Set the conditional execution predicate
+ Binary |= II->getPredicate(&MI) << 28;
// Encode S bit if MI modifies CPSR.
Binary |= getAddrMode1SBit(MI, TID);
@@ -429,8 +429,8 @@
unsigned ARMCodeEmitter::getAddrMode2InstrBinary(const MachineInstr &MI,
const TargetInstrDesc &TID,
unsigned Binary) {
- // FIXME: Assume CC is AL for now.
- Binary |= ARMCC::AL << 28;
+ // Set the conditional execution predicate
+ Binary |= II->getPredicate(&MI) << 28;
// Set first operand
Binary |= getMachineOpValue(MI, 0) << ARMII::RegRdShift;
@@ -470,8 +470,8 @@
unsigned ARMCodeEmitter::getAddrMode3InstrBinary(const MachineInstr &MI,
const TargetInstrDesc &TID,
unsigned Binary) {
- // FIXME: Assume CC is AL for now.
- Binary |= ARMCC::AL << 28;
+ // Set the conditional execution predicate
+ Binary |= II->getPredicate(&MI) << 28;
// Set first operand
Binary |= getMachineOpValue(MI, 0) << ARMII::RegRdShift;
@@ -507,8 +507,8 @@
unsigned ARMCodeEmitter::getAddrMode4InstrBinary(const MachineInstr &MI,
const TargetInstrDesc &TID,
unsigned Binary) {
- // FIXME: Assume CC is AL for now.
- Binary |= ARMCC::AL << 28;
+ // Set the conditional execution predicate
+ Binary |= II->getPredicate(&MI) << 28;
// Set first operand
Binary |= getMachineOpValue(MI, 0) << ARMII::RegRnShift;
Modified: llvm/trunk/lib/Target/ARM/ARMInstrInfo.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMInstrInfo.h?rev=57258&r1=57257&r2=57258&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMInstrInfo.h (original)
+++ llvm/trunk/lib/Target/ARM/ARMInstrInfo.h Tue Oct 7 14:05:35 2008
@@ -217,6 +217,12 @@
// Predication support.
virtual bool isPredicated(const MachineInstr *MI) const;
+ ARMCC::CondCodes getPredicate(const MachineInstr *MI) const {
+ int PIdx = MI->findFirstPredOperandIdx();
+ return PIdx != -1 ? (ARMCC::CondCodes)MI->getOperand(PIdx).getImm()
+ : ARMCC::AL;
+ }
+
virtual
bool PredicateInstruction(MachineInstr *MI,
const SmallVectorImpl &Pred) const;
From baldrick at free.fr Tue Oct 7 14:24:51 2008
From: baldrick at free.fr (Duncan Sands)
Date: Tue, 7 Oct 2008 21:24:51 +0200
Subject: [llvm-commits] [llvm] r57247 -
/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
In-Reply-To: <54924.76.220.41.203.1223402037.squirrel@webmail.apple.com>
References: <200810071703.m97H3GGL002647@zion.cs.uiuc.edu>
<54924.76.220.41.203.1223402037.squirrel@webmail.apple.com>
Message-ID: <200810072124.51364.baldrick@free.fr>
> FWIW, LegalizeIntegerTypes.cpp will eventually need to do
> something similar, and it'll need to account for non-power-of-two
> integer sizes also.
As long as there are testcases, I will deal with it when
I get back to working on LegalizeTypes.
Ciao,
Duncan.
From resistor at mac.com Tue Oct 7 15:22:30 2008
From: resistor at mac.com (Owen Anderson)
Date: Tue, 07 Oct 2008 20:22:30 -0000
Subject: [llvm-commits] [llvm] r57259 - in /llvm/trunk:
include/llvm/Target/TargetOptions.h lib/CodeGen/LiveIntervalAnalysis.cpp
lib/CodeGen/RegAllocLinearScan.cpp lib/CodeGen/SimpleRegisterCoalescing.cpp
lib/CodeGen/TwoAddressInstructionPass.cpp lib/Target/TargetMachine.cpp
Message-ID: <200810072022.m97KMUsO009373@zion.cs.uiuc.edu>
Author: resistor
Date: Tue Oct 7 15:22:28 2008
New Revision: 57259
URL: http://llvm.org/viewvc/llvm-project?rev=57259&view=rev
Log:
Add an option to enable StrongPHIElimination, for ease of testing.
Modified:
llvm/trunk/include/llvm/Target/TargetOptions.h
llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp
llvm/trunk/lib/CodeGen/RegAllocLinearScan.cpp
llvm/trunk/lib/CodeGen/SimpleRegisterCoalescing.cpp
llvm/trunk/lib/CodeGen/TwoAddressInstructionPass.cpp
llvm/trunk/lib/Target/TargetMachine.cpp
Modified: llvm/trunk/include/llvm/Target/TargetOptions.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Target/TargetOptions.h?rev=57259&r1=57258&r2=57259&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Target/TargetOptions.h (original)
+++ llvm/trunk/include/llvm/Target/TargetOptions.h Tue Oct 7 15:22:28 2008
@@ -102,6 +102,10 @@
/// which trades away generated code quality in favor of reducing
/// compile time.
extern bool EnableFastISel;
+
+ /// StrongPHIElim - This flag enables more aggressive PHI elimination
+ /// wth earlier copy coalescing.
+ extern bool StrongPHIElim;
} // End llvm namespace
Modified: llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp?rev=57259&r1=57258&r2=57259&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp (original)
+++ llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp Tue Oct 7 15:22:28 2008
@@ -30,6 +30,7 @@
#include "llvm/Target/TargetRegisterInfo.h"
#include "llvm/Target/TargetInstrInfo.h"
#include "llvm/Target/TargetMachine.h"
+#include "llvm/Target/TargetOptions.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Debug.h"
#include "llvm/ADT/Statistic.h"
@@ -67,8 +68,12 @@
AU.addRequired();
AU.addPreservedID(MachineLoopInfoID);
AU.addPreservedID(MachineDominatorsID);
- AU.addPreservedID(PHIEliminationID);
- AU.addRequiredID(PHIEliminationID);
+
+ if (!StrongPHIElim) {
+ AU.addPreservedID(PHIEliminationID);
+ AU.addRequiredID(PHIEliminationID);
+ }
+
AU.addRequiredID(TwoAddressInstructionPassID);
MachineFunctionPass::getAnalysisUsage(AU);
}
Modified: llvm/trunk/lib/CodeGen/RegAllocLinearScan.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/RegAllocLinearScan.cpp?rev=57259&r1=57258&r2=57259&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/RegAllocLinearScan.cpp (original)
+++ llvm/trunk/lib/CodeGen/RegAllocLinearScan.cpp Tue Oct 7 15:22:28 2008
@@ -26,6 +26,7 @@
#include "llvm/CodeGen/RegisterCoalescer.h"
#include "llvm/Target/TargetRegisterInfo.h"
#include "llvm/Target/TargetMachine.h"
+#include "llvm/Target/TargetOptions.h"
#include "llvm/Target/TargetInstrInfo.h"
#include "llvm/ADT/EquivalenceClasses.h"
#include "llvm/ADT/Statistic.h"
@@ -107,6 +108,8 @@
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
AU.addRequired();
+ if (StrongPHIElim)
+ AU.addRequiredID(StrongPHIEliminationID);
// Make sure PassManager knows which analyses to make available
// to coalescing and which analyses coalescing invalidates.
AU.addRequiredTransitive();
Modified: llvm/trunk/lib/CodeGen/SimpleRegisterCoalescing.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SimpleRegisterCoalescing.cpp?rev=57259&r1=57258&r2=57259&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SimpleRegisterCoalescing.cpp (original)
+++ llvm/trunk/lib/CodeGen/SimpleRegisterCoalescing.cpp Tue Oct 7 15:22:28 2008
@@ -25,6 +25,7 @@
#include "llvm/CodeGen/RegisterCoalescer.h"
#include "llvm/Target/TargetInstrInfo.h"
#include "llvm/Target/TargetMachine.h"
+#include "llvm/Target/TargetOptions.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Debug.h"
#include "llvm/ADT/SmallSet.h"
@@ -72,7 +73,10 @@
AU.addRequired();
AU.addPreserved();
AU.addPreservedID(MachineDominatorsID);
- AU.addPreservedID(PHIEliminationID);
+ if (StrongPHIElim)
+ AU.addPreservedID(StrongPHIEliminationID);
+ else
+ AU.addPreservedID(PHIEliminationID);
AU.addPreservedID(TwoAddressInstructionPassID);
MachineFunctionPass::getAnalysisUsage(AU);
}
Modified: llvm/trunk/lib/CodeGen/TwoAddressInstructionPass.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/TwoAddressInstructionPass.cpp?rev=57259&r1=57258&r2=57259&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/TwoAddressInstructionPass.cpp (original)
+++ llvm/trunk/lib/CodeGen/TwoAddressInstructionPass.cpp Tue Oct 7 15:22:28 2008
@@ -37,6 +37,7 @@
#include "llvm/Target/TargetRegisterInfo.h"
#include "llvm/Target/TargetInstrInfo.h"
#include "llvm/Target/TargetMachine.h"
+#include "llvm/Target/TargetOptions.h"
#include "llvm/Support/Compiler.h"
#include "llvm/Support/Debug.h"
#include "llvm/ADT/BitVector.h"
@@ -76,7 +77,10 @@
AU.addPreserved();
AU.addPreservedID(MachineLoopInfoID);
AU.addPreservedID(MachineDominatorsID);
- AU.addPreservedID(PHIEliminationID);
+ if (StrongPHIElim)
+ AU.addPreservedID(StrongPHIEliminationID);
+ else
+ AU.addPreservedID(PHIEliminationID);
MachineFunctionPass::getAnalysisUsage(AU);
}
Modified: llvm/trunk/lib/Target/TargetMachine.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/TargetMachine.cpp?rev=57259&r1=57258&r2=57259&view=diff
==============================================================================
--- llvm/trunk/lib/Target/TargetMachine.cpp (original)
+++ llvm/trunk/lib/Target/TargetMachine.cpp Tue Oct 7 15:22:28 2008
@@ -39,6 +39,7 @@
bool RealignStack;
bool VerboseAsm;
bool DisableJumpTables;
+ bool StrongPHIElim;
}
static cl::opt PrintCode("print-machineinstrs",
@@ -157,6 +158,12 @@
cl::location(DisableJumpTables),
cl::init(false));
+static cl::opt
+EnableStrongPHIElim(cl::Hidden, "strong-phi-elim",
+ cl::desc("Use strong PHI elimination."),
+ cl::location(StrongPHIElim),
+ cl::init(false));
+
//---------------------------------------------------------------------------
// TargetMachine Class
//
From evan.cheng at apple.com Tue Oct 7 15:34:36 2008
From: evan.cheng at apple.com (Evan Cheng)
Date: Tue, 7 Oct 2008 13:34:36 -0700
Subject: [llvm-commits] [llvm] r57257 -
/llvm/trunk/lib/Target/X86/X86InstrInfo.td
In-Reply-To: <200810071854.m97IsTFq006416@zion.cs.uiuc.edu>
References: <200810071854.m97IsTFq006416@zion.cs.uiuc.edu>
Message-ID: <562281E8-8029-4666-BAEA-765DAAA23F69@apple.com>
Hi Dale,
I think we ought to fix the bug in the local register allocator
instead. Is it not checking for aliases or sub-registers somewhere?
Thanks,
Evan
On Oct 7, 2008, at 11:54 AM, Dale Johannesen wrote:
> Author: johannes
> Date: Tue Oct 7 13:54:28 2008
> New Revision: 57257
>
> URL: http://llvm.org/viewvc/llvm-project?rev=57257&view=rev
> Log:
> Model hardwired inputs & outputs of x86 8-bit divides correctly.
> Fixes local RA miscompilation of gcc.c-torture/execute/20020904-1.c -
> O0.
>
>
> Modified:
> llvm/trunk/lib/Target/X86/X86InstrInfo.td
>
> Modified: llvm/trunk/lib/Target/X86/X86InstrInfo.td
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrInfo.td?rev=57257&r1=57256&r2=57257&view=diff
>
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- llvm/trunk/lib/Target/X86/X86InstrInfo.td (original)
> +++ llvm/trunk/lib/Target/X86/X86InstrInfo.td Tue Oct 7 13:54:28 2008
> @@ -728,7 +728,7 @@
> }
>
> // unsigned division/remainder
> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
> def DIV8r : I<0xF6, MRM6r, (outs), (ins GR8:$src), // AX/
> r8 = AL,AH
> "div{b}\t$src", []>;
> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
> @@ -738,7 +738,7 @@
> def DIV32r : I<0xF7, MRM6r, (outs), (ins GR32:$src), //
> EDX:EAX/r32 = EAX,EDX
> "div{l}\t$src", []>;
> let mayLoad = 1 in {
> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
> def DIV8m : I<0xF6, MRM6m, (outs), (ins i8mem:$src), // AX/
> [mem8] = AL,AH
> "div{b}\t$src", []>;
> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
> @@ -750,7 +750,7 @@
> }
>
> // Signed division/remainder.
> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
> def IDIV8r : I<0xF6, MRM7r, (outs), (ins GR8:$src), // AX/
> r8 = AL,AH
> "idiv{b}\t$src", []>;
> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
> @@ -760,7 +760,7 @@
> def IDIV32r: I<0xF7, MRM7r, (outs), (ins GR32:$src), //
> EDX:EAX/r32 = EAX,EDX
> "idiv{l}\t$src", []>;
> let mayLoad = 1, mayLoad = 1 in {
> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
> def IDIV8m : I<0xF6, MRM7m, (outs), (ins i8mem:$src), // AX/
> [mem8] = AL,AH
> "idiv{b}\t$src", []>;
> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From gohman at apple.com Tue Oct 7 15:39:12 2008
From: gohman at apple.com (Dan Gohman)
Date: Tue, 07 Oct 2008 20:39:12 -0000
Subject: [llvm-commits] [llvm] r57260 -
/llvm/trunk/test/CodeGen/X86/i256-add.ll
Message-ID: <200810072039.m97KdC6x009992@zion.cs.uiuc.edu>
Author: djg
Date: Tue Oct 7 15:39:12 2008
New Revision: 57260
URL: http://llvm.org/viewvc/llvm-project?rev=57260&view=rev
Log:
Add a testcase for i256 add. i256 isn't fully supported in
codegen right now, but add and subtract work.
Added:
llvm/trunk/test/CodeGen/X86/i256-add.ll
Added: llvm/trunk/test/CodeGen/X86/i256-add.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/i256-add.ll?rev=57260&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/X86/i256-add.ll (added)
+++ llvm/trunk/test/CodeGen/X86/i256-add.ll Tue Oct 7 15:39:12 2008
@@ -0,0 +1,18 @@
+; RUN: llvm-as < %s | llc -march=x86 > %t
+; RUN: grep adcl %t | count 7
+; RUN: grep sbbl %t | count 7
+
+define void @add(i256* %p, i256* %q) nounwind {
+ %a = load i256* %p
+ %b = load i256* %q
+ %c = add i256 %a, %b
+ store i256 %c, i256* %p
+ ret void
+}
+define void @sub(i256* %p, i256* %q) nounwind {
+ %a = load i256* %p
+ %b = load i256* %q
+ %c = sub i256 %a, %b
+ store i256 %c, i256* %p
+ ret void
+}
From dalej at apple.com Tue Oct 7 15:44:10 2008
From: dalej at apple.com (Dale Johannesen)
Date: Tue, 7 Oct 2008 13:44:10 -0700
Subject: [llvm-commits] [llvm] r57257 -
/llvm/trunk/lib/Target/X86/X86InstrInfo.td
In-Reply-To: <562281E8-8029-4666-BAEA-765DAAA23F69@apple.com>
References: <200810071854.m97IsTFq006416@zion.cs.uiuc.edu>
<562281E8-8029-4666-BAEA-765DAAA23F69@apple.com>
Message-ID:
On Oct 7, 2008, at 1:34 PMPDT, Evan Cheng wrote:
> Hi Dale,
>
> I think we ought to fix the bug in the local register allocator
> instead. Is it not checking for aliases or sub-registers somewhere?
>
> Thanks,
>
> Evan
Surely not "instead", the code I changed was clearly wrong.
Here are before-and-after dumps. I have not tracked it through the
code, but it looks like it's assuming imp-use physregs are supposed to
match in type with the definition of that reg. That seems like a
reasonable assumption to me since the code generator has complete
control of those types.
Before
> Starting RegAlloc of: %AX = MOV16rr %reg1029
> Regs have values: [AL,%reg1026] [CX,%reg1029]
> Last use of CX[%reg1029], removing it from live set
> Last use of CL[%reg1029], removing it from live set
> Last use of CH[%reg1029], removing it from live set
> Spilling register AL containing %reg1026 to stack slot #4
> Register AX [%reg3] is never used, removing it frame live list
> Register AL [%reg2] is never used, removing it frame live list
> Register AH [%reg1] is never used, removing it frame live list
> Register EAX [%reg17] is never used, removing it frame live list
>
> Starting RegAlloc of: DIV8r %reg1026, %AX,
> %EFLAGS, %AL, %AH
> Regs have values:
> Reloading %reg1026 into AL <<<<<<<<< wrong
> Last use of AL[%reg1026], removing it from live set
> Last use of AH[%reg1], removing it from live set
> Register AX [%reg3] is never used, removing it frame live list
> Register AL [%reg2] is never used, removing it frame live list
> Register AH [%reg1] is never used, removing it frame live list
> Register EAX [%reg17] is never used, removing it frame live list
> Register EFLAGS [%reg23] is never used, removing it frame live list
After
> Starting RegAlloc of: %AX = MOV16rr %reg1029
> Regs have values: [AL,%reg1026] [CX,%reg1029]
> Last use of CX[%reg1029], removing it from live set
> Last use of CL[%reg1029], removing it from live set
> Last use of CH[%reg1029], removing it from live set
> Spilling register AL containing %reg1026 to stack slot #4
>
> Starting RegAlloc of: DIV8r %reg1026, %AL, %AH def,dead>, %EFLAGS, %AX
> Regs have values: [AH,%reg0] [AL,%reg0] [AX,%reg0]
> Reloading %reg1026 into CL
> Last use of CL[%reg1026], removing it from live set
> Last use of AX[%reg3], removing it from live set
> Last use of AL[%reg3], removing it from live set
> Last use of AH[%reg3], removing it from live set
> Register AH [%reg1] is never used, removing it frame live list
> Register AX [%reg3] is never used, removing it frame live list
> Register EAX [%reg17] is never used, removing it frame live list
> Register EFLAGS [%reg23] is never used, removing it frame live list
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.cs.uiuc.edu/pipermail/llvm-commits/attachments/20081007/6112d9cd/attachment.html
From evan.cheng at apple.com Tue Oct 7 16:01:19 2008
From: evan.cheng at apple.com (Evan Cheng)
Date: Tue, 7 Oct 2008 14:01:19 -0700
Subject: [llvm-commits] [llvm] r57257 -
/llvm/trunk/lib/Target/X86/X86InstrInfo.td
In-Reply-To:
References: <200810071854.m97IsTFq006416@zion.cs.uiuc.edu>
<562281E8-8029-4666-BAEA-765DAAA23F69@apple.com>
Message-ID:
On Oct 7, 2008, at 1:44 PM, Dale Johannesen wrote:
>
> On Oct 7, 2008, at 1:34 PMPDT, Evan Cheng wrote:
>
>> Hi Dale,
>>
>> I think we ought to fix the bug in the local register allocator
>> instead. Is it not checking for aliases or sub-registers somewhere?
>>
>> Thanks,
>>
>> Evan
>
> Surely not "instead", the code I changed was clearly wrong.
>
> Here are before-and-after dumps. I have not tracked it through the
> code, but it looks like it's assuming imp-use physregs are supposed
> to match in type with the definition of that reg. That seems like a
> reasonable assumption to me since the code generator has complete
> control of those types.
This is a local liveness bug. AX == AL + AH. The def of AX by MOV16rr
should not be dead. I assume this is a bug that's exposed by fastisel?
Owen, can you work with Dale on this?
Thanks,
Evan
>
> Before
>
>> Starting RegAlloc of: %AX = MOV16rr %reg1029
>> Regs have values: [AL,%reg1026] [CX,%reg1029]
>> Last use of CX[%reg1029], removing it from live set
>> Last use of CL[%reg1029], removing it from live set
>> Last use of CH[%reg1029], removing it from live set
>> Spilling register AL containing %reg1026 to stack slot #4
>> Register AX [%reg3] is never used, removing it frame live list
>> Register AL [%reg2] is never used, removing it frame live list
>> Register AH [%reg1] is never used, removing it frame live list
>> Register EAX [%reg17] is never used, removing it frame live list
>>
>> Starting RegAlloc of: DIV8r %reg1026, %AX,
>> %EFLAGS, %AL, %AH
>> Regs have values:
>> Reloading %reg1026 into AL <<<<<<<<< wrong
>> Last use of AL[%reg1026], removing it from live set
>> Last use of AH[%reg1], removing it from live set
>> Register AX [%reg3] is never used, removing it frame live list
>> Register AL [%reg2] is never used, removing it frame live list
>> Register AH [%reg1] is never used, removing it frame live list
>> Register EAX [%reg17] is never used, removing it frame live list
>> Register EFLAGS [%reg23] is never used, removing it frame live list
>
>
> After
>
>> Starting RegAlloc of: %AX = MOV16rr %reg1029
>> Regs have values: [AL,%reg1026] [CX,%reg1029]
>> Last use of CX[%reg1029], removing it from live set
>> Last use of CL[%reg1029], removing it from live set
>> Last use of CH[%reg1029], removing it from live set
>> Spilling register AL containing %reg1026 to stack slot #4
>>
>> Starting RegAlloc of: DIV8r %reg1026, %AL, %AH> def,dead>, %EFLAGS, %AX
>> Regs have values: [AH,%reg0] [AL,%reg0] [AX,%reg0]
>> Reloading %reg1026 into CL
>> Last use of CL[%reg1026], removing it from live set
>> Last use of AX[%reg3], removing it from live set
>> Last use of AL[%reg3], removing it from live set
>> Last use of AH[%reg3], removing it from live set
>> Register AH [%reg1] is never used, removing it frame live list
>> Register AX [%reg3] is never used, removing it frame live list
>> Register EAX [%reg17] is never used, removing it frame live list
>> Register EFLAGS [%reg23] is never used, removing it frame live list
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.cs.uiuc.edu/pipermail/llvm-commits/attachments/20081007/0edda733/attachment.html
From grosbach at apple.com Tue Oct 7 16:01:51 2008
From: grosbach at apple.com (Jim Grosbach)
Date: Tue, 07 Oct 2008 21:01:51 -0000
Subject: [llvm-commits] [llvm] r57261 -
/llvm/trunk/lib/Target/ARM/ARMInstrInfo.h
Message-ID: <200810072101.m97L1pOb010729@zion.cs.uiuc.edu>
Author: grosbach
Date: Tue Oct 7 16:01:51 2008
New Revision: 57261
URL: http://llvm.org/viewvc/llvm-project?rev=57261&view=rev
Log:
need ARM.h for ARMCC definition
Modified:
llvm/trunk/lib/Target/ARM/ARMInstrInfo.h
Modified: llvm/trunk/lib/Target/ARM/ARMInstrInfo.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMInstrInfo.h?rev=57261&r1=57260&r2=57261&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMInstrInfo.h (original)
+++ llvm/trunk/lib/Target/ARM/ARMInstrInfo.h Tue Oct 7 16:01:51 2008
@@ -16,6 +16,7 @@
#include "llvm/Target/TargetInstrInfo.h"
#include "ARMRegisterInfo.h"
+#include "ARM.h"
namespace llvm {
class ARMSubtarget;
From matthijs at stdin.nl Tue Oct 7 16:02:48 2008
From: matthijs at stdin.nl (Matthijs Kooijman)
Date: Tue, 7 Oct 2008 23:02:48 +0200
Subject: [llvm-commits] PR2765 Patch
In-Reply-To: <85dfcd7f0810071020w4a0cf3b7vb3fc21e90867c346@mail.gmail.com>
References: <85dfcd7f0810071020w4a0cf3b7vb3fc21e90867c346@mail.gmail.com>
Message-ID: <20081007210248.GP6091@katherina.student.utwente.nl>
Hi Andrew,
> + for (Function::const_arg_iterator I = OldFunc->arg_begin(),
> + E = OldFunc->arg_end(); I != E; ++I)
> + if (Argument* Anew = dyn_cast(ValueMap[I]))
What does ValueMap[I] return when the argument is removed? I would expect
NULL, but in that case you should be using dyn_cast_or_null IIRC?
> + Anew->addAttr( OldFunc->getAttributes()
> + .getParamAttributes(I->getArgNo() + 1));
> + NewFunc->setAttributes(NewFunc->getAttributes()
> + .addAttr(0, OldFunc->getAttributes()
> + .getRetAttributes()));
> + NewFunc->setAttributes(NewFunc->getAttributes()
> + .addAttr(~0, OldFunc->getAttributes()
> + .getFnAttributes()));
There is also a Function::addAttribute. Any particular reason not to use it?
For the ~0 case, using Function::addFnAttr might be even better, since it
prevents the use of the ~0 magic number.
Perhaps there should be a addReturnAttr as well? I can't find it, so perhaps
you could add it as well (probably submit that as a separate patch).
Alternatively, I guess Devang should have a look at this, since he was working
on this.
Gr.
Matthijs
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://lists.cs.uiuc.edu/pipermail/llvm-commits/attachments/20081007/192ab361/attachment.bin
From gohman at apple.com Tue Oct 7 16:03:21 2008
From: gohman at apple.com (Dan Gohman)
Date: Tue, 7 Oct 2008 14:03:21 -0700
Subject: [llvm-commits] [llvm] r57257 -
/llvm/trunk/lib/Target/X86/X86InstrInfo.td
In-Reply-To: <562281E8-8029-4666-BAEA-765DAAA23F69@apple.com>
References: <200810071854.m97IsTFq006416@zion.cs.uiuc.edu>
<562281E8-8029-4666-BAEA-765DAAA23F69@apple.com>
Message-ID: <0951BE97-1242-47F5-B03F-52D9B53E6BBD@apple.com>
This looks like the same problem I found related to how fast-isel
emits shifts. The local register allocator's liveness code
does not check aliases or subregisters at all right now.
We could fix it, but on the other hand it's arguably sloppy for
instruction selectors to not precisely describe their physical
register uses.
Dan
On Oct 7, 2008, at 1:34 PM, Evan Cheng wrote:
> Hi Dale,
>
> I think we ought to fix the bug in the local register allocator
> instead. Is it not checking for aliases or sub-registers somewhere?
>
> Thanks,
>
> Evan
>
> On Oct 7, 2008, at 11:54 AM, Dale Johannesen wrote:
>
>> Author: johannes
>> Date: Tue Oct 7 13:54:28 2008
>> New Revision: 57257
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=57257&view=rev
>> Log:
>> Model hardwired inputs & outputs of x86 8-bit divides correctly.
>> Fixes local RA miscompilation of gcc.c-torture/execute/20020904-1.c -
>> O0.
>>
>>
>> Modified:
>> llvm/trunk/lib/Target/X86/X86InstrInfo.td
>>
>> Modified: llvm/trunk/lib/Target/X86/X86InstrInfo.td
>> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrInfo.td?rev=57257&r1=57256&r2=57257&view=diff
>>
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =
>> =====================================================================
>> --- llvm/trunk/lib/Target/X86/X86InstrInfo.td (original)
>> +++ llvm/trunk/lib/Target/X86/X86InstrInfo.td Tue Oct 7 13:54:28
>> 2008
>> @@ -728,7 +728,7 @@
>> }
>>
>> // unsigned division/remainder
>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>> def DIV8r : I<0xF6, MRM6r, (outs), (ins GR8:$src), // AX/
>> r8 = AL,AH
>> "div{b}\t$src", []>;
>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>> @@ -738,7 +738,7 @@
>> def DIV32r : I<0xF7, MRM6r, (outs), (ins GR32:$src), //
>> EDX:EAX/r32 = EAX,EDX
>> "div{l}\t$src", []>;
>> let mayLoad = 1 in {
>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>> def DIV8m : I<0xF6, MRM6m, (outs), (ins i8mem:$src), // AX/
>> [mem8] = AL,AH
>> "div{b}\t$src", []>;
>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>> @@ -750,7 +750,7 @@
>> }
>>
>> // Signed division/remainder.
>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>> def IDIV8r : I<0xF6, MRM7r, (outs), (ins GR8:$src), // AX/
>> r8 = AL,AH
>> "idiv{b}\t$src", []>;
>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>> @@ -760,7 +760,7 @@
>> def IDIV32r: I<0xF7, MRM7r, (outs), (ins GR32:$src), //
>> EDX:EAX/r32 = EAX,EDX
>> "idiv{l}\t$src", []>;
>> let mayLoad = 1, mayLoad = 1 in {
>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>> def IDIV8m : I<0xF6, MRM7m, (outs), (ins i8mem:$src), // AX/
>> [mem8] = AL,AH
>> "idiv{b}\t$src", []>;
>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>>
>>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From dpatel at apple.com Tue Oct 7 16:07:16 2008
From: dpatel at apple.com (Devang Patel)
Date: Tue, 7 Oct 2008 14:07:16 -0700
Subject: [llvm-commits] PR2765 Patch
In-Reply-To: <20081007210248.GP6091@katherina.student.utwente.nl>
References: <85dfcd7f0810071020w4a0cf3b7vb3fc21e90867c346@mail.gmail.com>
<20081007210248.GP6091@katherina.student.utwente.nl>
Message-ID:
On Oct 7, 2008, at 2:02 PM, Matthijs Kooijman wrote:
> Perhaps there should be a addReturnAttr as well? I can't find it, so
> perhaps
> you could add it as well (probably submit that as a separate patch).
That's a good idea.
-
Devang
From grosbach at apple.com Tue Oct 7 16:08:09 2008
From: grosbach at apple.com (Jim Grosbach)
Date: Tue, 07 Oct 2008 21:08:09 -0000
Subject: [llvm-commits] [llvm] r57262 -
/llvm/trunk/lib/Target/ARM/ARMInstrInfo.td
Message-ID: <200810072108.m97L897J010946@zion.cs.uiuc.edu>
Author: grosbach
Date: Tue Oct 7 16:08:09 2008
New Revision: 57262
URL: http://llvm.org/viewvc/llvm-project?rev=57262&view=rev
Log:
Unconditional branch instruction encoding fix. Needs to use ABI, not AXI, to get the proper opcode bits.
Modified:
llvm/trunk/lib/Target/ARM/ARMInstrInfo.td
Modified: llvm/trunk/lib/Target/ARM/ARMInstrInfo.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMInstrInfo.td?rev=57262&r1=57261&r2=57262&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMInstrInfo.td (original)
+++ llvm/trunk/lib/Target/ARM/ARMInstrInfo.td Tue Oct 7 16:08:09 2008
@@ -567,7 +567,7 @@
// B is "predicable" since it can be xformed into a Bcc.
let isBarrier = 1 in {
let isPredicable = 1 in
- def B : AXI<0xA, (outs), (ins brtarget:$target), Branch, "b $target",
+ def B : ABI<{0,1,0,1}, (outs), (ins brtarget:$target), Branch, "b $target",
[(br bb:$target)]>;
let isNotDuplicable = 1, isIndirectBranch = 1 in {
From evan.cheng at apple.com Tue Oct 7 16:15:55 2008
From: evan.cheng at apple.com (Evan Cheng)
Date: Tue, 7 Oct 2008 14:15:55 -0700
Subject: [llvm-commits] [llvm] r57257 -
/llvm/trunk/lib/Target/X86/X86InstrInfo.td
In-Reply-To: <0951BE97-1242-47F5-B03F-52D9B53E6BBD@apple.com>
References: <200810071854.m97IsTFq006416@zion.cs.uiuc.edu>
<562281E8-8029-4666-BAEA-765DAAA23F69@apple.com>
<0951BE97-1242-47F5-B03F-52D9B53E6BBD@apple.com>
Message-ID:
On Oct 7, 2008, at 2:03 PM, Dan Gohman wrote:
> This looks like the same problem I found related to how fast-isel
> emits shifts. The local register allocator's liveness code
> does not check aliases or subregisters at all right now.
That needs to be fixed.
>
>
> We could fix it, but on the other hand it's arguably sloppy for
> instruction selectors to not precisely describe their physical
> register uses.
I agree. In this case DVI8r should say it defines AL, AH and uses AL,
AH which makes it clear it reads 2 values and outputs 2. On the other
hand, it should not matter if it says it uses AX which is the same as
AL + AH.
Evan
>
>
> Dan
>
> On Oct 7, 2008, at 1:34 PM, Evan Cheng wrote:
>
>> Hi Dale,
>>
>> I think we ought to fix the bug in the local register allocator
>> instead. Is it not checking for aliases or sub-registers somewhere?
>>
>> Thanks,
>>
>> Evan
>>
>> On Oct 7, 2008, at 11:54 AM, Dale Johannesen wrote:
>>
>>> Author: johannes
>>> Date: Tue Oct 7 13:54:28 2008
>>> New Revision: 57257
>>>
>>> URL: http://llvm.org/viewvc/llvm-project?rev=57257&view=rev
>>> Log:
>>> Model hardwired inputs & outputs of x86 8-bit divides correctly.
>>> Fixes local RA miscompilation of gcc.c-torture/execute/
>>> 20020904-1.c -
>>> O0.
>>>
>>>
>>> Modified:
>>> llvm/trunk/lib/Target/X86/X86InstrInfo.td
>>>
>>> Modified: llvm/trunk/lib/Target/X86/X86InstrInfo.td
>>> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrInfo.td?rev=57257&r1=57256&r2=57257&view=diff
>>>
>>> =
>>> =
>>> =
>>> =
>>> =
>>> =
>>> =
>>> =
>>> =
>>> =
>>> ====================================================================
>>> --- llvm/trunk/lib/Target/X86/X86InstrInfo.td (original)
>>> +++ llvm/trunk/lib/Target/X86/X86InstrInfo.td Tue Oct 7 13:54:28
>>> 2008
>>> @@ -728,7 +728,7 @@
>>> }
>>>
>>> // unsigned division/remainder
>>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>>> def DIV8r : I<0xF6, MRM6r, (outs), (ins GR8:$src), // AX/
>>> r8 = AL,AH
>>> "div{b}\t$src", []>;
>>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>>> @@ -738,7 +738,7 @@
>>> def DIV32r : I<0xF7, MRM6r, (outs), (ins GR32:$src), //
>>> EDX:EAX/r32 = EAX,EDX
>>> "div{l}\t$src", []>;
>>> let mayLoad = 1 in {
>>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>>> def DIV8m : I<0xF6, MRM6m, (outs), (ins i8mem:$src), // AX/
>>> [mem8] = AL,AH
>>> "div{b}\t$src", []>;
>>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>>> @@ -750,7 +750,7 @@
>>> }
>>>
>>> // Signed division/remainder.
>>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>>> def IDIV8r : I<0xF6, MRM7r, (outs), (ins GR8:$src), // AX/
>>> r8 = AL,AH
>>> "idiv{b}\t$src", []>;
>>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>>> @@ -760,7 +760,7 @@
>>> def IDIV32r: I<0xF7, MRM7r, (outs), (ins GR32:$src), //
>>> EDX:EAX/r32 = EAX,EDX
>>> "idiv{l}\t$src", []>;
>>> let mayLoad = 1, mayLoad = 1 in {
>>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>>> def IDIV8m : I<0xF6, MRM7m, (outs), (ins i8mem:$src), // AX/
>>> [mem8] = AL,AH
>>> "idiv{b}\t$src", []>;
>>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>>>
>>>
>>> _______________________________________________
>>> llvm-commits mailing list
>>> llvm-commits at cs.uiuc.edu
>>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From dalej at apple.com Tue Oct 7 16:21:09 2008
From: dalej at apple.com (Dale Johannesen)
Date: Tue, 7 Oct 2008 14:21:09 -0700
Subject: [llvm-commits] [llvm] r57257 -
/llvm/trunk/lib/Target/X86/X86InstrInfo.td
In-Reply-To:
References: <200810071854.m97IsTFq006416@zion.cs.uiuc.edu>
<562281E8-8029-4666-BAEA-765DAAA23F69@apple.com>
<0951BE97-1242-47F5-B03F-52D9B53E6BBD@apple.com>
Message-ID: <15C81154-C32F-4D72-A34C-B69731E907E1@apple.com>
On Oct 7, 2008, at 2:15 PMPDT, Evan Cheng wrote:
>
> On Oct 7, 2008, at 2:03 PM, Dan Gohman wrote:
>
>> This looks like the same problem I found related to how fast-isel
>> emits shifts. The local register allocator's liveness code
>> does not check aliases or subregisters at all right now.
>
> That needs to be fixed.
>
>>
>>
>> We could fix it, but on the other hand it's arguably sloppy for
>> instruction selectors to not precisely describe their physical
>> register uses.
>
> I agree. In this case DVI8r should say it defines AL, AH and uses AL,
> AH which makes it clear it reads 2 values and outputs 2.
No, it reads 1 value and outputs two. It is not the same as DIV16 and
DIV32.
The way I have it matches Intel docs.
> On the other
> hand, it should not matter if it says it uses AX which is the same as
> AL + AH.
>
> Evan
>
>>
>>
>> Dan
>>
>> On Oct 7, 2008, at 1:34 PM, Evan Cheng wrote:
>>
>>> Hi Dale,
>>>
>>> I think we ought to fix the bug in the local register allocator
>>> instead. Is it not checking for aliases or sub-registers somewhere?
>>>
>>> Thanks,
>>>
>>> Evan
>>>
>>> On Oct 7, 2008, at 11:54 AM, Dale Johannesen wrote:
>>>
>>>> Author: johannes
>>>> Date: Tue Oct 7 13:54:28 2008
>>>> New Revision: 57257
>>>>
>>>> URL: http://llvm.org/viewvc/llvm-project?rev=57257&view=rev
>>>> Log:
>>>> Model hardwired inputs & outputs of x86 8-bit divides correctly.
>>>> Fixes local RA miscompilation of gcc.c-torture/execute/
>>>> 20020904-1.c -
>>>> O0.
>>>>
>>>>
>>>> Modified:
>>>> llvm/trunk/lib/Target/X86/X86InstrInfo.td
>>>>
>>>> Modified: llvm/trunk/lib/Target/X86/X86InstrInfo.td
>>>> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrInfo.td?rev=57257&r1=57256&r2=57257&view=diff
>>>>
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> =
>>>> ===================================================================
>>>> --- llvm/trunk/lib/Target/X86/X86InstrInfo.td (original)
>>>> +++ llvm/trunk/lib/Target/X86/X86InstrInfo.td Tue Oct 7 13:54:28
>>>> 2008
>>>> @@ -728,7 +728,7 @@
>>>> }
>>>>
>>>> // unsigned division/remainder
>>>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>>>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>>>> def DIV8r : I<0xF6, MRM6r, (outs), (ins GR8:$src), //
>>>> AX/
>>>> r8 = AL,AH
>>>> "div{b}\t$src", []>;
>>>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>>>> @@ -738,7 +738,7 @@
>>>> def DIV32r : I<0xF7, MRM6r, (outs), (ins GR32:$src), //
>>>> EDX:EAX/r32 = EAX,EDX
>>>> "div{l}\t$src", []>;
>>>> let mayLoad = 1 in {
>>>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>>>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>>>> def DIV8m : I<0xF6, MRM6m, (outs), (ins i8mem:$src), // AX/
>>>> [mem8] = AL,AH
>>>> "div{b}\t$src", []>;
>>>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>>>> @@ -750,7 +750,7 @@
>>>> }
>>>>
>>>> // Signed division/remainder.
>>>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>>>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>>>> def IDIV8r : I<0xF6, MRM7r, (outs), (ins GR8:$src), //
>>>> AX/
>>>> r8 = AL,AH
>>>> "idiv{b}\t$src", []>;
>>>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>>>> @@ -760,7 +760,7 @@
>>>> def IDIV32r: I<0xF7, MRM7r, (outs), (ins GR32:$src), //
>>>> EDX:EAX/r32 = EAX,EDX
>>>> "idiv{l}\t$src", []>;
>>>> let mayLoad = 1, mayLoad = 1 in {
>>>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>>>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>>>> def IDIV8m : I<0xF6, MRM7m, (outs), (ins i8mem:$src), // AX/
>>>> [mem8] = AL,AH
>>>> "idiv{b}\t$src", []>;
>>>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>>>>
>>>>
>>>> _______________________________________________
>>>> llvm-commits mailing list
>>>> llvm-commits at cs.uiuc.edu
>>>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>>>
>>> _______________________________________________
>>> llvm-commits mailing list
>>> llvm-commits at cs.uiuc.edu
>>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From gohman at apple.com Tue Oct 7 16:21:39 2008
From: gohman at apple.com (Dan Gohman)
Date: Tue, 7 Oct 2008 14:21:39 -0700
Subject: [llvm-commits] [llvm] r57247 -
/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
In-Reply-To: <200810072124.51364.baldrick@free.fr>
References: <200810071703.m97H3GGL002647@zion.cs.uiuc.edu>
<54924.76.220.41.203.1223402037.squirrel@webmail.apple.com>
<200810072124.51364.baldrick@free.fr>
Message-ID: <11381FC2-3AE5-4072-94EC-83DBF5BB5DDC@apple.com>
On Oct 7, 2008, at 12:24 PM, Duncan Sands wrote:
>> FWIW, LegalizeIntegerTypes.cpp will eventually need to do
>> something similar, and it'll need to account for non-power-of-two
>> integer sizes also.
>
> As long as there are testcases, I will deal with it when
> I get back to working on LegalizeTypes.
Thanks! Andrew added dejagnu testcases for i128 arithmetic on Alpha,
and I added one for i256 arithmetic on x86, so I believe the basic
functionality is covered.
Dan
From criswell at uiuc.edu Tue Oct 7 16:23:45 2008
From: criswell at uiuc.edu (John Criswell)
Date: Tue, 07 Oct 2008 21:23:45 -0000
Subject: [llvm-commits] [poolalloc] r57263 -
/poolalloc/trunk/lib/DSA/StdLibPass.cpp
Message-ID: <200810072123.m97LNjTO011561@zion.cs.uiuc.edu>
Author: criswell
Date: Tue Oct 7 16:23:44 2008
New Revision: 57263
URL: http://llvm.org/viewvc/llvm-project?rev=57263&view=rev
Log:
When collapsing the DSNodes of return values and parameters, ensure that we
only collapse the return value if it is, in fact, a pointer.
Modified:
poolalloc/trunk/lib/DSA/StdLibPass.cpp
Modified: poolalloc/trunk/lib/DSA/StdLibPass.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/DSA/StdLibPass.cpp?rev=57263&r1=57262&r2=57263&view=diff
==============================================================================
--- poolalloc/trunk/lib/DSA/StdLibPass.cpp (original)
+++ poolalloc/trunk/lib/DSA/StdLibPass.cpp Tue Oct 7 16:23:44 2008
@@ -151,7 +151,8 @@
toMerge[0].mergeWith(toMerge[y]);
if (recFuncs[x].action.collapse) {
- Graph.getNodeForValue(CI).getNode()->foldNodeCompletely();
+ if (isa(CI->getType()))
+ Graph.getNodeForValue(CI).getNode()->foldNodeCompletely();
for (unsigned y = 1; y < CI->getNumOperands(); ++y)
if (isa(CI->getOperand(y)->getType()))
if (DSNode * Node=Graph.getNodeForValue(CI->getOperand(y)).getNode())
From evan.cheng at apple.com Tue Oct 7 16:29:44 2008
From: evan.cheng at apple.com (Evan Cheng)
Date: Tue, 7 Oct 2008 14:29:44 -0700
Subject: [llvm-commits] [llvm] r57257 -
/llvm/trunk/lib/Target/X86/X86InstrInfo.td
In-Reply-To: <15C81154-C32F-4D72-A34C-B69731E907E1@apple.com>
References: <200810071854.m97IsTFq006416@zion.cs.uiuc.edu>
<562281E8-8029-4666-BAEA-765DAAA23F69@apple.com>
<0951BE97-1242-47F5-B03F-52D9B53E6BBD@apple.com>
<15C81154-C32F-4D72-A34C-B69731E907E1@apple.com>
Message-ID: <7A3355B2-456F-4B23-A018-872CF0FCAD54@apple.com>
On Oct 7, 2008, at 2:21 PM, Dale Johannesen wrote:
>
> On Oct 7, 2008, at 2:15 PMPDT, Evan Cheng wrote:
>
>>
>> On Oct 7, 2008, at 2:03 PM, Dan Gohman wrote:
>>
>>> This looks like the same problem I found related to how fast-isel
>>> emits shifts. The local register allocator's liveness code
>>> does not check aliases or subregisters at all right now.
>>
>> That needs to be fixed.
>>
>>>
>>>
>>> We could fix it, but on the other hand it's arguably sloppy for
>>> instruction selectors to not precisely describe their physical
>>> register uses.
>>
>> I agree. In this case DVI8r should say it defines AL, AH and uses AL,
>> AH which makes it clear it reads 2 values and outputs 2.
>
> No, it reads 1 value and outputs two. It is not the same as DIV16 and
> DIV32.
> The way I have it matches Intel docs.
Ok. It's good to match what Intel manual says. But that's additional
goodness. Previously DIV16r is marked as using AL, AH and the implicit
use is copied to AX. While this is not ideal, it's not incorrect.
Local liveness cannot mark AX as dead.
Evan
>
>
>> On the other
>> hand, it should not matter if it says it uses AX which is the same as
>> AL + AH.
>>
>> Evan
>>
>>>
>>>
>>> Dan
>>>
>>> On Oct 7, 2008, at 1:34 PM, Evan Cheng wrote:
>>>
>>>> Hi Dale,
>>>>
>>>> I think we ought to fix the bug in the local register allocator
>>>> instead. Is it not checking for aliases or sub-registers somewhere?
>>>>
>>>> Thanks,
>>>>
>>>> Evan
>>>>
>>>> On Oct 7, 2008, at 11:54 AM, Dale Johannesen wrote:
>>>>
>>>>> Author: johannes
>>>>> Date: Tue Oct 7 13:54:28 2008
>>>>> New Revision: 57257
>>>>>
>>>>> URL: http://llvm.org/viewvc/llvm-project?rev=57257&view=rev
>>>>> Log:
>>>>> Model hardwired inputs & outputs of x86 8-bit divides correctly.
>>>>> Fixes local RA miscompilation of gcc.c-torture/execute/
>>>>> 20020904-1.c -
>>>>> O0.
>>>>>
>>>>>
>>>>> Modified:
>>>>> llvm/trunk/lib/Target/X86/X86InstrInfo.td
>>>>>
>>>>> Modified: llvm/trunk/lib/Target/X86/X86InstrInfo.td
>>>>> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrInfo.td?rev=57257&r1=57256&r2=57257&view=diff
>>>>>
>>>>> =
>>>>> =
>>>>> =
>>>>> =
>>>>> =
>>>>> =
>>>>> =
>>>>> =
>>>>> =
>>>>> =
>>>>> =
>>>>> =
>>>>> ==================================================================
>>>>> --- llvm/trunk/lib/Target/X86/X86InstrInfo.td (original)
>>>>> +++ llvm/trunk/lib/Target/X86/X86InstrInfo.td Tue Oct 7 13:54:28
>>>>> 2008
>>>>> @@ -728,7 +728,7 @@
>>>>> }
>>>>>
>>>>> // unsigned division/remainder
>>>>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>>>>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>>>>> def DIV8r : I<0xF6, MRM6r, (outs), (ins GR8:$src), //
>>>>> AX/
>>>>> r8 = AL,AH
>>>>> "div{b}\t$src", []>;
>>>>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>>>>> @@ -738,7 +738,7 @@
>>>>> def DIV32r : I<0xF7, MRM6r, (outs), (ins GR32:$src), //
>>>>> EDX:EAX/r32 = EAX,EDX
>>>>> "div{l}\t$src", []>;
>>>>> let mayLoad = 1 in {
>>>>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>>>>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>>>>> def DIV8m : I<0xF6, MRM6m, (outs), (ins i8mem:$src), // AX/
>>>>> [mem8] = AL,AH
>>>>> "div{b}\t$src", []>;
>>>>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>>>>> @@ -750,7 +750,7 @@
>>>>> }
>>>>>
>>>>> // Signed division/remainder.
>>>>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>>>>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>>>>> def IDIV8r : I<0xF6, MRM7r, (outs), (ins GR8:$src), //
>>>>> AX/
>>>>> r8 = AL,AH
>>>>> "idiv{b}\t$src", []>;
>>>>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>>>>> @@ -760,7 +760,7 @@
>>>>> def IDIV32r: I<0xF7, MRM7r, (outs), (ins GR32:$src), //
>>>>> EDX:EAX/r32 = EAX,EDX
>>>>> "idiv{l}\t$src", []>;
>>>>> let mayLoad = 1, mayLoad = 1 in {
>>>>> -let Defs = [AX,EFLAGS], Uses = [AL,AH] in
>>>>> +let Defs = [AL,AH,EFLAGS], Uses = [AX] in
>>>>> def IDIV8m : I<0xF6, MRM7m, (outs), (ins i8mem:$src), // AX/
>>>>> [mem8] = AL,AH
>>>>> "idiv{b}\t$src", []>;
>>>>> let Defs = [AX,DX,EFLAGS], Uses = [AX,DX] in
>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> llvm-commits mailing list
>>>>> llvm-commits at cs.uiuc.edu
>>>>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>>>>
>>>> _______________________________________________
>>>> llvm-commits mailing list
>>>> llvm-commits at cs.uiuc.edu
>>>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>>>
>>> _______________________________________________
>>> llvm-commits mailing list
>>> llvm-commits at cs.uiuc.edu
>>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
From gohman at apple.com Tue Oct 7 16:50:37 2008
From: gohman at apple.com (Dan Gohman)
Date: Tue, 07 Oct 2008 21:50:37 -0000
Subject: [llvm-commits] [llvm] r57264 -
/llvm/trunk/lib/Target/X86/X86FastISel.cpp
Message-ID: <200810072150.m97Lob1Z012444@zion.cs.uiuc.edu>
Author: djg
Date: Tue Oct 7 16:50:36 2008
New Revision: 57264
URL: http://llvm.org/viewvc/llvm-project?rev=57264&view=rev
Log:
Instead of emitting an implicit use for the super-register of
X86::CL that was used, emit an EXTRACT_SUBREG from the CL
super-register to CL. This more precisely describes how the
CL register is being used.
Modified:
llvm/trunk/lib/Target/X86/X86FastISel.cpp
Modified: llvm/trunk/lib/Target/X86/X86FastISel.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86FastISel.cpp?rev=57264&r1=57263&r2=57264&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86FastISel.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86FastISel.cpp Tue Oct 7 16:50:36 2008
@@ -866,12 +866,16 @@
unsigned Op1Reg = getRegForValue(I->getOperand(1));
if (Op1Reg == 0) return false;
TII.copyRegToReg(*MBB, MBB->end(), CReg, Op1Reg, RC, RC);
+
+ // The shift instruction uses X86::CL. If we defined a super-register
+ // of X86::CL, emit an EXTRACT_SUBREG to precisely describe what
+ // we're doing here.
+ if (CReg != X86::CL)
+ BuildMI(MBB, TII.get(TargetInstrInfo::EXTRACT_SUBREG), X86::CL)
+ .addReg(CReg).addImm(X86::SUBREG_8BIT);
+
unsigned ResultReg = createResultReg(RC);
- BuildMI(MBB, TII.get(OpReg), ResultReg).addReg(Op0Reg)
- // FIXME: The "Local" register allocator's physreg liveness doesn't
- // recognize subregs. Adding the superreg of CL that's actually defined
- // prevents it from being re-allocated for this instruction.
- .addReg(CReg, false, true);
+ BuildMI(MBB, TII.get(OpReg), ResultReg).addReg(Op0Reg);
UpdateValueMap(I, ResultReg);
return true;
}
@@ -976,7 +980,7 @@
BuildMI(MBB, TII.get(CopyOpc), CopyReg).addReg(InputReg);
// Then issue an extract_subreg.
- unsigned ResultReg = FastEmitInst_extractsubreg(CopyReg,1); // x86_subreg_8bit
+ unsigned ResultReg = FastEmitInst_extractsubreg(CopyReg, X86::SUBREG_8BIT);
if (!ResultReg)
return false;
From gohman at apple.com Tue Oct 7 17:03:27 2008
From: gohman at apple.com (Dan Gohman)
Date: Tue, 07 Oct 2008 22:03:27 -0000
Subject: [llvm-commits] [llvm] r57265 -
/llvm/trunk/lib/CodeGen/SelectionDAG/FastISel.cpp
Message-ID: <200810072203.m97M3RN8012856@zion.cs.uiuc.edu>
Author: djg
Date: Tue Oct 7 17:03:27 2008
New Revision: 57265
URL: http://llvm.org/viewvc/llvm-project?rev=57265&view=rev
Log:
Avoid emitting redundant materializations of integer constants
for things like null pointers, which at this level aren't
different from regular integer constants.
Modified:
llvm/trunk/lib/CodeGen/SelectionDAG/FastISel.cpp
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/FastISel.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/FastISel.cpp?rev=57265&r1=57264&r2=57265&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/FastISel.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/FastISel.cpp Tue Oct 7 17:03:27 2008
@@ -81,7 +81,9 @@
} else if (isa(V)) {
Reg = TargetMaterializeAlloca(cast(V));
} else if (isa(V)) {
- Reg = FastEmit_i(VT, VT, ISD::Constant, 0);
+ // Translate this as an integer zero so that it can be
+ // local-CSE'd with actual integer zeros.
+ Reg = getRegForValue(Constant::getNullValue(TD.getIntPtrType()));
} else if (ConstantFP *CF = dyn_cast(V)) {
Reg = FastEmit_f(VT, VT, ISD::ConstantFP, CF);
@@ -95,8 +97,7 @@
APFloat::rmTowardZero) != APFloat::opOK) {
APInt IntVal(IntBitWidth, 2, x);
- unsigned IntegerReg = FastEmit_i(IntVT.getSimpleVT(), IntVT.getSimpleVT(),
- ISD::Constant, IntVal.getZExtValue());
+ unsigned IntegerReg = getRegForValue(ConstantInt::get(IntVal));
if (IntegerReg != 0)
Reg = FastEmit_r(IntVT.getSimpleVT(), VT, ISD::SINT_TO_FP, IntegerReg);
}
From gohman at apple.com Tue Oct 7 17:10:33 2008
From: gohman at apple.com (Dan Gohman)
Date: Tue, 07 Oct 2008 22:10:33 -0000
Subject: [llvm-commits] [llvm] r57266 -
/llvm/trunk/lib/Target/X86/X86FastISel.cpp
Message-ID: <200810072210.m97MAX31013137@zion.cs.uiuc.edu>
Author: djg
Date: Tue Oct 7 17:10:33 2008
New Revision: 57266
URL: http://llvm.org/viewvc/llvm-project?rev=57266&view=rev
Log:
Add MBB successors and physreg Uses in the same order that
SDISel typically adds them in. This makes it a little easier
to compare FastISel output with SDISel output.
Modified:
llvm/trunk/lib/Target/X86/X86FastISel.cpp
Modified: llvm/trunk/lib/Target/X86/X86FastISel.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86FastISel.cpp?rev=57266&r1=57265&r2=57266&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86FastISel.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86FastISel.cpp Tue Oct 7 17:10:33 2008
@@ -784,8 +784,8 @@
default:
return false;
}
- MBB->addSuccessor(TrueMBB);
FastEmitBranch(FalseMBB);
+ MBB->addSuccessor(TrueMBB);
return true;
}
}
@@ -797,9 +797,8 @@
BuildMI(MBB, TII.get(X86::TEST8rr)).addReg(OpReg).addReg(OpReg);
BuildMI(MBB, TII.get(X86::JNE)).addMBB(TrueMBB);
- MBB->addSuccessor(TrueMBB);
-
FastEmitBranch(FalseMBB);
+ MBB->addSuccessor(TrueMBB);
return true;
}
@@ -1180,10 +1179,8 @@
MIB.addReg(X86::EBX);
// Add implicit physical register uses to the call.
- while (!RegArgs.empty()) {
- MIB.addReg(RegArgs.back());
- RegArgs.pop_back();
- }
+ for (unsigned i = 0, e = RegArgs.size(); i != e; ++i)
+ MIB.addReg(RegArgs[i]);
// Issue CALLSEQ_END
unsigned AdjStackUp = TM.getRegisterInfo()->getCallFrameDestroyOpcode();
From neil at daikokuya.co.uk Tue Oct 7 17:19:28 2008
From: neil at daikokuya.co.uk (Neil Booth)
Date: Wed, 8 Oct 2008 07:19:28 +0900
Subject: [llvm-commits] [llvm] r57185
- /llvm/trunk/lib/Support/APFloat.cpp
In-Reply-To: <3D552C79-1370-4B36-8A6B-7CEE082AE4DC@apple.com>
References: <200810061822.m96IMTgD007250@zion.cs.uiuc.edu>
<0C450614-92AA-4337-B0EA-53797DA53326@apple.com>
<20081007131921.GF19669@daikokuya.co.uk>
<3D552C79-1370-4B36-8A6B-7CEE082AE4DC@apple.com>
Message-ID: <20081007221928.GI19669@daikokuya.co.uk>
Dale Johannesen wrote:-
> Good to hear from you on this one.
>
> What the rest of the compiler wants to know is whether a conversion
> can be done without loss of information. I.e. if you convert type A
> to type B, then back to type A, you get the original value. Right now
> it's using the return value == fsOK check
> to figure that out. I suppose the various call sites could be taught
> about NaNs but it really seems better to keep those details buried in
> APFloat somehow.
>
> I guess we could add a separate "conversion doesn't lose information"
> return value to the conversion routines, or even convert back and
> compare at the call sites, although that seems silly when the first
> conversion has all the needed information. I'm not so sure it's worth
> preserving strict IEEE behavior in all these edge cases, though,
> what's the value of that in LLVM? How would you approach the problem?
That seems reasonable. However LLVM may also be interested in
simulating the target CPU, in a JIT or run-time library, or asking
"does this operation raise any hardware exceptions, and which ones",
this question being important for optimization? This was the
original intent of the code and should be preserved. I'd like to
preserve that. So could you add an extra flag for this case?
> When I implemented the -0.0 conversion to int, I thought that was what
> IEEE754 calls for, but I missed the definition of inexact, obscurely
> placed in 7.4(4). 6.3 is clear that the result should have a negative
> sign, and that's not implementable on a twos complement machine, yet
> none of the exceptions seems to apply; I guess the standard calls for
> quietly producing an answer known to be wrong. This one really seems
> like a bug in the standard.
This one should be special-cased at the call site. I think the loss
of IEEE semantics, which are there for good reason and may even be
being relied on elsewhere in APFloat, is a very bad idea here.
Chris, what do you think?
Neil.
From tonic at nondot.org Tue Oct 7 17:21:04 2008
From: tonic at nondot.org (Tanya Lattner)
Date: Tue, 07 Oct 2008 22:21:04 -0000
Subject: [llvm-commits] [llvm] r57267 - in /llvm/trunk:
autoconf/configure.ac configure
Message-ID: <200810072221.m97ML4kQ026855@zion.cs.uiuc.edu>
Author: tbrethou
Date: Tue Oct 7 17:21:03 2008
New Revision: 57267
URL: http://llvm.org/viewvc/llvm-project?rev=57267&view=rev
Log:
Fix configure issue where configure
turned "obj-c++" into "obj" in the langs line.
Update configure script.
Modified:
llvm/trunk/autoconf/configure.ac
llvm/trunk/configure
Modified: llvm/trunk/autoconf/configure.ac
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/autoconf/configure.ac?rev=57267&r1=57266&r2=57267&view=diff
==============================================================================
--- llvm/trunk/autoconf/configure.ac (original)
+++ llvm/trunk/autoconf/configure.ac Tue Oct 7 17:21:03 2008
@@ -872,7 +872,7 @@
llvmgccmajvers=[`echo $llvmgccversion | sed 's/^\([0-9]\).*/\1/'`]
AC_SUBST(LLVMGCC_VERSION,$llvmgccversion)
AC_SUBST(LLVMGCC_MAJVERS,$llvmgccmajvers)
- llvmgcclangs=[`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ -]*\).*/\1/'`]
+ llvmgcclangs=[`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ ]*\).*/\1/'`]
AC_SUBST(LLVMGCC_LANGS,$llvmgcclangs)
AC_MSG_RESULT([ok])
fi
Modified: llvm/trunk/configure
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/configure?rev=57267&r1=57266&r2=57267&view=diff
==============================================================================
--- llvm/trunk/configure (original)
+++ llvm/trunk/configure Tue Oct 7 17:21:03 2008
@@ -34246,7 +34246,7 @@
LLVMGCC_MAJVERS=$llvmgccmajvers
- llvmgcclangs=`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ -]*\).*/\1/'`
+ llvmgcclangs=`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ ]*\).*/\1/'`
LLVMGCC_LANGS=$llvmgcclangs
{ echo "$as_me:$LINENO: result: ok" >&5
From echristo at apple.com Tue Oct 7 17:33:45 2008
From: echristo at apple.com (Eric Christopher)
Date: Tue, 07 Oct 2008 22:33:45 -0000
Subject: [llvm-commits] [llvm] r57268 - /llvm/trunk/include/llvm/Function.h
Message-ID: <200810072233.m97MXkRK027555@zion.cs.uiuc.edu>
Author: echristo
Date: Tue Oct 7 17:33:44 2008
New Revision: 57268
URL: http://llvm.org/viewvc/llvm-project?rev=57268&view=rev
Log:
Fix disagreement about where the attributes are
~0 != ~0U.
Modified:
llvm/trunk/include/llvm/Function.h
Modified: llvm/trunk/include/llvm/Function.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Function.h?rev=57268&r1=57267&r2=57268&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Function.h (original)
+++ llvm/trunk/include/llvm/Function.h Tue Oct 7 17:33:44 2008
@@ -158,7 +158,7 @@
///
void addFnAttr(Attributes N) {
// Function Attributes are stored at ~0 index
- addAttribute(~0, N);
+ addAttribute(~0U, N);
}
/// hasGC/getGC/setGC/clearGC - The name of the garbage collection algorithm
From tonic at nondot.org Tue Oct 7 17:34:35 2008
From: tonic at nondot.org (Tanya Lattner)
Date: Tue, 07 Oct 2008 22:34:35 -0000
Subject: [llvm-commits] [llvm] r57269 - in /llvm/branches/release_24:
autoconf/configure.ac configure
Message-ID: <200810072234.m97MYamP027599@zion.cs.uiuc.edu>
Author: tbrethou
Date: Tue Oct 7 17:34:35 2008
New Revision: 57269
URL: http://llvm.org/viewvc/llvm-project?rev=57269&view=rev
Log:
Merge from mainline.
Modified:
llvm/branches/release_24/autoconf/configure.ac
llvm/branches/release_24/configure
Modified: llvm/branches/release_24/autoconf/configure.ac
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_24/autoconf/configure.ac?rev=57269&r1=57268&r2=57269&view=diff
==============================================================================
--- llvm/branches/release_24/autoconf/configure.ac (original)
+++ llvm/branches/release_24/autoconf/configure.ac Tue Oct 7 17:34:35 2008
@@ -872,7 +872,7 @@
llvmgccmajvers=[`echo $llvmgccversion | sed 's/^\([0-9]\).*/\1/'`]
AC_SUBST(LLVMGCC_VERSION,$llvmgccversion)
AC_SUBST(LLVMGCC_MAJVERS,$llvmgccmajvers)
- llvmgcclangs=[`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ -]*\).*/\1/'`]
+ llvmgcclangs=[`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ ]*\).*/\1/'`]
AC_SUBST(LLVMGCC_LANGS,$llvmgcclangs)
AC_MSG_RESULT([ok])
fi
Modified: llvm/branches/release_24/configure
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_24/configure?rev=57269&r1=57268&r2=57269&view=diff
==============================================================================
--- llvm/branches/release_24/configure (original)
+++ llvm/branches/release_24/configure Tue Oct 7 17:34:35 2008
@@ -34246,7 +34246,7 @@
LLVMGCC_MAJVERS=$llvmgccmajvers
- llvmgcclangs=`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ -]*\).*/\1/'`
+ llvmgcclangs=`"$LLVMGCC" -v --help 2>&1 | grep '^Configured with:' | sed 's/^.*--enable-languages=\([^ ]*\).*/\1/'`
LLVMGCC_LANGS=$llvmgcclangs
{ echo "$as_me:$LINENO: result: ok" >&5
From gohman at apple.com Tue Oct 7 18:00:56 2008
From: gohman at apple.com (Dan Gohman)
Date: Tue, 07 Oct 2008 23:00:56 -0000
Subject: [llvm-commits] [llvm] r57270 - in /llvm/trunk:
lib/CodeGen/LLVMTargetMachine.cpp
test/CodeGen/X86/2008-05-21-CoalescerBug.ll
Message-ID: <200810072300.m97N0u3i028552@zion.cs.uiuc.edu>
Author: djg
Date: Tue Oct 7 18:00:56 2008
New Revision: 57270
URL: http://llvm.org/viewvc/llvm-project?rev=57270&view=rev
Log:
Remove -disable-fast-isel. Use cl::boolOrDefault with -fast-isel
instead.
So now: -fast-isel or -fast-isel=true enable fast-isel, and
-fast-isel=false disables it. Fast-isel is also on by default
with -fast, and off by default otherwise.
Modified:
llvm/trunk/lib/CodeGen/LLVMTargetMachine.cpp
llvm/trunk/test/CodeGen/X86/2008-05-21-CoalescerBug.ll
Modified: llvm/trunk/lib/CodeGen/LLVMTargetMachine.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/LLVMTargetMachine.cpp?rev=57270&r1=57269&r2=57270&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/LLVMTargetMachine.cpp (original)
+++ llvm/trunk/lib/CodeGen/LLVMTargetMachine.cpp Tue Oct 7 18:00:56 2008
@@ -56,12 +56,9 @@
// Enable or disable FastISel. Both options are needed, because
// FastISel is enabled by default with -fast, and we wish to be
// able to enable or disable fast-isel independently from -fast.
-static cl::opt
+static cl::opt
EnableFastISelOption("fast-isel", cl::Hidden,
cl::desc("Enable the experimental \"fast\" instruction selector"));
-static cl::opt
-DisableFastISelOption("disable-fast-isel", cl::Hidden,
- cl::desc("Disable the experimental \"fast\" instruction selector"));
FileModel::Model
LLVMTargetMachine::addPassesToEmitFile(PassManagerBase &PM,
@@ -175,10 +172,8 @@
// Standard Lower-Level Passes.
// Enable FastISel with -fast, but allow that to be overridden.
- assert((!EnableFastISelOption || !DisableFastISelOption) &&
- "Both -fast-isel and -disable-fast-isel given!");
- if (EnableFastISelOption ||
- (Fast && !DisableFastISelOption))
+ if (EnableFastISelOption == cl::BOU_TRUE ||
+ (Fast && EnableFastISelOption != cl::BOU_FALSE))
EnableFastISel = true;
// Ask the target for an isel.
Modified: llvm/trunk/test/CodeGen/X86/2008-05-21-CoalescerBug.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/2008-05-21-CoalescerBug.ll?rev=57270&r1=57269&r2=57270&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/X86/2008-05-21-CoalescerBug.ll (original)
+++ llvm/trunk/test/CodeGen/X86/2008-05-21-CoalescerBug.ll Tue Oct 7 18:00:56 2008
@@ -1,4 +1,4 @@
-; RUN: llvm-as < %s | llc -march=x86 -fast -disable-fast-isel | grep mov | count 5
+; RUN: llvm-as < %s | llc -march=x86 -fast -fast-isel=false | grep mov | count 5
; PR2343
%llvm.dbg.anchor.type = type { i32, i32 }
From gohman at apple.com Tue Oct 7 18:01:45 2008
From: gohman at apple.com (Dan Gohman)
Date: Tue, 7 Oct 2008 16:01:45 -0700
Subject: [llvm-commits] [llvm] r56930 -
/llvm/trunk/lib/CodeGen/LLVMTargetMachine.cpp
In-Reply-To:
References: <200810012039.m91KdKb2028324@zion.cs.uiuc.edu>
Message-ID: <24E3355D-BEAC-4F59-8620-9D31CB7947EC@apple.com>
On Oct 4, 2008, at 1:29 PM, Chris Lattner wrote:
>
> On Oct 1, 2008, at 1:39 PM, Dan Gohman wrote:
>
>> +// Enable or disable FastISel. Both options are needed, because
>> +// FastISel is enabled by default with -fast, and we wish to be
>> +// able to enable or disable fast-isel independently from -fast.
>> +static cl::opt
>> +EnableFastISelOption("fast-isel", cl::Hidden,
>> + cl::desc("Enable the experimental \"fast\" instruction
>> selector"));
>> +static cl::opt
>> +DisableFastISelOption("disable-fast-isel", cl::Hidden,
>> + cl::desc("Disable the experimental \"fast\" instruction
>> selector"));
>
> This seems like it should be a tri-state/enum option, not two
> different and mutually conflicting options.
Aha, there's even a boolOrDefault tri-state option parser
already available. I've removed -disable-fast-isel in
favor of this. Thanks!
Dan
From kremenek at apple.com Tue Oct 7 18:10:46 2008
From: kremenek at apple.com (Ted Kremenek)
Date: Tue, 07 Oct 2008 23:10:46 -0000
Subject: [llvm-commits] [llvm] r57276 - /llvm/tags/checker/checker-109/
Message-ID: <200810072310.m97NAkeH029154@zion.cs.uiuc.edu>
Author: kremenek
Date: Tue Oct 7 18:10:46 2008
New Revision: 57276
URL: http://llvm.org/viewvc/llvm-project?rev=57276&view=rev
Log:
Tagging checker-109.
Added:
llvm/tags/checker/checker-109/
- copied from r57275, llvm/trunk/
From tonic at nondot.org Tue Oct 7 18:17:49 2008
From: tonic at nondot.org (Tanya Lattner)
Date: Tue, 07 Oct 2008 23:17:49 -0000
Subject: [llvm-commits] [llvm] r57278 -
/llvm/branches/release_24/include/llvm/Function.h
Message-ID: <200810072317.m97NHnAN029582@zion.cs.uiuc.edu>
Author: tbrethou
Date: Tue Oct 7 18:17:48 2008
New Revision: 57278
URL: http://llvm.org/viewvc/llvm-project?rev=57278&view=rev
Log:
Merge from mainline.
Fix disagreement about where the attributes are
~0 != ~0U.
Modified:
llvm/branches/release_24/include/llvm/Function.h
Modified: llvm/branches/release_24/include/llvm/Function.h
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_24/include/llvm/Function.h?rev=57278&r1=57277&r2=57278&view=diff
==============================================================================
--- llvm/branches/release_24/include/llvm/Function.h (original)
+++ llvm/branches/release_24/include/llvm/Function.h Tue Oct 7 18:17:48 2008
@@ -158,7 +158,7 @@
///
void addFnAttr(Attributes N) {
// Function Attributes are stored at ~0 index
- addAttribute(~0, N);
+ addAttribute(~0U, N);
}
/// hasGC/getGC/setGC/clearGC - The name of the garbage collection algorithm
From kremenek at apple.com Tue Oct 7 18:18:20 2008
From: kremenek at apple.com (Ted Kremenek)
Date: Tue, 07 Oct 2008 23:18:20 -0000
Subject: [llvm-commits] [llvm] r57279 - /llvm/tags/checker/checker-109/
Message-ID: <200810072318.m97NIK81029615@zion.cs.uiuc.edu>
Author: kremenek
Date: Tue Oct 7 18:18:20 2008
New Revision: 57279
URL: http://llvm.org/viewvc/llvm-project?rev=57279&view=rev
Log:
Removing checker-109.
Removed:
llvm/tags/checker/checker-109/
From gohman at apple.com Tue Oct 7 18:30:36 2008
From: gohman at apple.com (Dan Gohman)
Date: Tue, 07 Oct 2008 23:30:36 -0000
Subject: [llvm-commits] [test-suite] r57281 -
/test-suite/trunk/autoconf/configure.ac
Message-ID: <200810072330.m97NUagZ030230@zion.cs.uiuc.edu>
Author: djg
Date: Tue Oct 7 18:30:36 2008
New Revision: 57281
URL: http://llvm.org/viewvc/llvm-project?rev=57281&view=rev
Log:
Add '=DIR' to the --with-llvmobj help, for consistency with all the
other options.
Modified:
test-suite/trunk/autoconf/configure.ac
Modified: test-suite/trunk/autoconf/configure.ac
URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/autoconf/configure.ac?rev=57281&r1=57280&r2=57281&view=diff
==============================================================================
--- test-suite/trunk/autoconf/configure.ac (original)
+++ test-suite/trunk/autoconf/configure.ac Tue Oct 7 18:30:36 2008
@@ -58,7 +58,7 @@
dnl Location of LLVM object code
AC_ARG_WITH(llvmobj,
- AS_HELP_STRING([--with-llvmobj],Location of LLVM Object Code),
+ AS_HELP_STRING([--with-llvmobj=DIR],Location of LLVM Object Code),
AC_SUBST(LLVM_OBJ,[$withval]),
AC_SUBST(LLVM_OBJ,[`cd ../..; pwd`]))
From kremenek at apple.com Tue Oct 7 18:35:58 2008
From: kremenek at apple.com (Ted Kremenek)
Date: Tue, 07 Oct 2008 23:35:58 -0000
Subject: [llvm-commits] [llvm] r57283 - /llvm/tags/checker/checker-109/
Message-ID: <200810072335.m97NZw5a030448@zion.cs.uiuc.edu>
Author: kremenek
Date: Tue Oct 7 18:35:57 2008
New Revision: 57283
URL: http://llvm.org/viewvc/llvm-project?rev=57283&view=rev
Log:
Tagging checker-109.
Added:
llvm/tags/checker/checker-109/
- copied from r57282, llvm/trunk/
From sam at rfc1149.net Tue Oct 7 10:30:38 2008
From: sam at rfc1149.net (Samuel Tardieu)
Date: Tue, 07 Oct 2008 17:30:38 +0200
Subject: [llvm-commits] [PATCH] Add include where needed
Message-ID: <20081007153038.15951.75226.stgit@arrakis.enst.fr>
This is needed to get "stderr", "EOF", "sprintf", and so on.
GCC 4.4.0 cannot compile LLVM without that in Release mode.
---
.../Interpreter/ExternalFunctions.cpp | 1 +
lib/ExecutionEngine/JIT/JITMemoryManager.cpp | 1 +
lib/System/DynamicLibrary.cpp | 1 +
lib/Target/PIC16/PIC16InstrInfo.cpp | 1 +
lib/Target/PowerPC/PPCMachOWriterInfo.cpp | 1 +
lib/Transforms/Scalar/GVN.cpp | 1 +
lib/Transforms/Utils/UnrollLoop.cpp | 1 +
lib/VMCore/PassManager.cpp | 1 +
utils/TableGen/InstrEnumEmitter.cpp | 1 +
utils/TableGen/TGLexer.cpp | 1 +
10 files changed, 10 insertions(+), 0 deletions(-)
diff --git a/lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp b/lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp
index 684d7db..66a26cf 100644
--- a/lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp
+++ b/lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp
@@ -27,6 +27,7 @@
#include "llvm/Target/TargetData.h"
#include "llvm/Support/ManagedStatic.h"
#include
+#include
#include