Re: [llvm-commits] Major regressions

2007-04-22 Thread Christopher Lamb

On Apr 22, 2007, at 1:40 AM, Chris Lattner wrote:



On Apr 21, 2007, at 4:28 PM, Christopher Lamb wrote:



On Apr 21, 2007, at 6:12 PM, Reid Spencer wrote:


On Sat, 2007-04-21 at 18:07 -0500, Christopher Lamb wrote:

I'm getting a regression after my fixes that's coming from
getABIAlignment not finding an alignment to use for a 
type,
is this a bug?


It could be.  isn't a useful vector so it probably  
doesn't

have an ABI Alignment. It should, however, default to whatever the
target's alignment is for float. Perhaps that case isn't covered in
TargetData or there's something else wrong with TargetData?

Did you walk through it in the debugger?


Yes. It appears that TargetData doesn't have logic to match the case
of vector types smaller than the smallest defined ABI vector type.
It's asserting in TargetData::getAlignmentInfo:

assert(BestMatchIdx != -1 && "Didn't find alignment info for this
datatype!");


Ahh.


I don't think it has enough information to be able to determine
whether or not it's being asked for the alignment of a smaller vector
type that could be mapped onto a non-vector type.

My feeling is that in this case getAlignmentInfo should return a
conservative fallback alignment the same way that's done for  
integers.


I think it should fall back to the ABI alignment of the scalar type.
If a target doesn't have an entry for a vector type, we can assume
that it will be scalarized.


Here's a patch to do it.
--
Christopher Lamb



degenerate_vectors.diff
Description: Binary data




___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-04-21 Thread Chris Lattner

On Apr 21, 2007, at 4:28 PM, Christopher Lamb wrote:

>
> On Apr 21, 2007, at 6:12 PM, Reid Spencer wrote:
>
>> On Sat, 2007-04-21 at 18:07 -0500, Christopher Lamb wrote:
>>> I'm getting a regression after my fixes that's coming from
>>> getABIAlignment not finding an alignment to use for a 
>>> type,
>>> is this a bug?
>>
>> It could be.  isn't a useful vector so it probably doesn't
>> have an ABI Alignment. It should, however, default to whatever the
>> target's alignment is for float. Perhaps that case isn't covered in
>> TargetData or there's something else wrong with TargetData?
>>
>> Did you walk through it in the debugger?
>
> Yes. It appears that TargetData doesn't have logic to match the case
> of vector types smaller than the smallest defined ABI vector type.
> It's asserting in TargetData::getAlignmentInfo:
>
> assert(BestMatchIdx != -1 && "Didn't find alignment info for this
> datatype!");

Ahh.

> I don't think it has enough information to be able to determine
> whether or not it's being asked for the alignment of a smaller vector
> type that could be mapped onto a non-vector type.
>
> My feeling is that in this case getAlignmentInfo should return a
> conservative fallback alignment the same way that's done for integers.

I think it should fall back to the ABI alignment of the scalar type.   
If a target doesn't have an entry for a vector type, we can assume  
that it will be scalarized.

-Chris 
___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-04-21 Thread Chris Lattner
On Apr 21, 2007, at 4:12 PM, Reid Spencer wrote:
> On Sat, 2007-04-21 at 18:07 -0500, Christopher Lamb wrote:
>> I'm getting a regression after my fixes that's coming from
>> getABIAlignment not finding an alignment to use for a   
>> type,
>> is this a bug?
>
> It could be.  isn't a useful vector so it probably doesn't
> have an ABI Alignment.

Single element vector types are important, but they don't get much  
testing.  For example, MMX supports <1 x i64>.

> It should, however, default to whatever the
> target's alignment is for float. Perhaps that case isn't covered in
> TargetData or there's something else wrong with TargetData?

I agree, if not explicitly specified, it should default to the scalar  
alignment.

-Chris
___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-04-21 Thread Christopher Lamb


On Apr 21, 2007, at 6:41 PM, Reid Spencer wrote:


On Sat, 2007-04-21 at 18:28 -0500, Christopher Lamb wrote:

On Apr 21, 2007, at 6:12 PM, Reid Spencer wrote:


On Sat, 2007-04-21 at 18:07 -0500, Christopher Lamb wrote:

I'm getting a regression after my fixes that's coming from
getABIAlignment not finding an alignment to use for a 
type,
is this a bug?


It could be.  isn't a useful vector so it probably  
doesn't

have an ABI Alignment. It should, however, default to whatever the
target's alignment is for float. Perhaps that case isn't covered in
TargetData or there's something else wrong with TargetData?

Did you walk through it in the debugger?


Yes. It appears that TargetData doesn't have logic to match the case
of vector types smaller than the smallest defined ABI vector type.
It's asserting in TargetData::getAlignmentInfo:

assert(BestMatchIdx != -1 && "Didn't find alignment info for this
datatype!");


That makes sense.



I don't think it has enough information to be able to determine
whether or not it's being asked for the alignment of a smaller vector
type that could be mapped onto a non-vector type.


What is your datalayout specification?


It's MacOS X's data layout:
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"



My feeling is that in this case getAlignmentInfo should return a
conservative fallback alignment the same way that's done for  
integers.


Perhaps, we'll need to discuss with Duncan and Chris though.


That's fine. I've split my patch into parts that should be able to be  
applied independently. Only the second part depends on this getting  
fixed.


--
Christopher Lamb



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-04-21 Thread Reid Spencer
On Sat, 2007-04-21 at 18:28 -0500, Christopher Lamb wrote:
> On Apr 21, 2007, at 6:12 PM, Reid Spencer wrote:
> 
> > On Sat, 2007-04-21 at 18:07 -0500, Christopher Lamb wrote:
> >> I'm getting a regression after my fixes that's coming from
> >> getABIAlignment not finding an alignment to use for a   
> >> type,
> >> is this a bug?
> >
> > It could be.  isn't a useful vector so it probably doesn't
> > have an ABI Alignment. It should, however, default to whatever the
> > target's alignment is for float. Perhaps that case isn't covered in
> > TargetData or there's something else wrong with TargetData?
> >
> > Did you walk through it in the debugger?
> 
> Yes. It appears that TargetData doesn't have logic to match the case  
> of vector types smaller than the smallest defined ABI vector type.  
> It's asserting in TargetData::getAlignmentInfo:
> 
> assert(BestMatchIdx != -1 && "Didn't find alignment info for this  
> datatype!");

That makes sense.

> 
> I don't think it has enough information to be able to determine  
> whether or not it's being asked for the alignment of a smaller vector  
> type that could be mapped onto a non-vector type.

What is your datalayout specification?

> 
> My feeling is that in this case getAlignmentInfo should return a  
> conservative fallback alignment the same way that's done for integers.

Perhaps, we'll need to discuss with Duncan and Chris though. 

Reid.

> 
> --
> Christopher Lamb
> 
> 
> 
> ___
> llvm-commits mailing list
> llvm-commits@cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits

___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-04-21 Thread Christopher Lamb

On Apr 21, 2007, at 6:12 PM, Reid Spencer wrote:

> On Sat, 2007-04-21 at 18:07 -0500, Christopher Lamb wrote:
>> I'm getting a regression after my fixes that's coming from
>> getABIAlignment not finding an alignment to use for a   
>> type,
>> is this a bug?
>
> It could be.  isn't a useful vector so it probably doesn't
> have an ABI Alignment. It should, however, default to whatever the
> target's alignment is for float. Perhaps that case isn't covered in
> TargetData or there's something else wrong with TargetData?
>
> Did you walk through it in the debugger?

Yes. It appears that TargetData doesn't have logic to match the case  
of vector types smaller than the smallest defined ABI vector type.  
It's asserting in TargetData::getAlignmentInfo:

assert(BestMatchIdx != -1 && "Didn't find alignment info for this  
datatype!");

I don't think it has enough information to be able to determine  
whether or not it's being asked for the alignment of a smaller vector  
type that could be mapped onto a non-vector type.

My feeling is that in this case getAlignmentInfo should return a  
conservative fallback alignment the same way that's done for integers.

--
Christopher Lamb



___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-04-21 Thread Reid Spencer
On Sat, 2007-04-21 at 18:07 -0500, Christopher Lamb wrote:
> I'm getting a regression after my fixes that's coming from
> getABIAlignment not finding an alignment to use for a  type,
> is this a bug?

It could be.  isn't a useful vector so it probably doesn't
have an ABI Alignment. It should, however, default to whatever the
target's alignment is for float. Perhaps that case isn't covered in
TargetData or there's something else wrong with TargetData?

Did you walk through it in the debugger?

Reid.

> 
> --
> Christopher Lamb
> 
> 
> 
> 
> On Apr 21, 2007, at 12:21 PM, Reid Spencer wrote:
> 
> > Jeff,
> > 
> > 
> > I'm seeing these too. They all seem to be related to Christopher
> > Lamb's
> > alignment changes. If he doesn't step up to fix soon, I'll revert
> > the
> > changes.
> > 
> > 
> > Reid.
> > 
> > 
> > On Sat, 2007-04-21 at 07:30 -0700, Jeff Cohen wrote:
> > > Commits in the last 12 hours or so have broken 34 regression tests
> > > and 
> > > caused 21 failure in llvm-test.  They appear to be concentrated in
> > > the 
> > > vector area.
> > > 
> > > 
> > > ___
> > > llvm-commits mailing list
> > > llvm-commits@cs.uiuc.edu
> > > http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
> > 
> > 
> > ___
> > llvm-commits mailing list
> > llvm-commits@cs.uiuc.edu
> > http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
> 
> 
> 
> 
> 
> 
> 
> 
> ___
> llvm-commits mailing list
> llvm-commits@cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits

___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-04-21 Thread Christopher Lamb
I'm getting a regression after my fixes that's coming from  
getABIAlignment not finding an alignment to use for a   
type, is this a bug?


--
Christopher Lamb


On Apr 21, 2007, at 12:21 PM, Reid Spencer wrote:


Jeff,

I'm seeing these too. They all seem to be related to Christopher  
Lamb's

alignment changes. If he doesn't step up to fix soon, I'll revert the
changes.

Reid.

On Sat, 2007-04-21 at 07:30 -0700, Jeff Cohen wrote:
Commits in the last 12 hours or so have broken 34 regression tests  
and
caused 21 failure in llvm-test.  They appear to be concentrated in  
the

vector area.

___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits






___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-04-21 Thread Christopher Lamb
The regressions are related to the following code in  
SelectionDAG.cpp. MVT::getTypeForValueType asserts if passed a Vector  
as VT.


  if (Alignment == 0) { // Ensure that codegen never sees alignment 0
const Type *Ty = MVT::getTypeForValueType(VT);
Alignment = TLI.getTargetData()->getABITypeAlignment(Ty);
  }

Suggestions on how to get the ABI alignment for vector types?
--
Christopher Lamb



On Apr 21, 2007, at 12:21 PM, Reid Spencer wrote:


Jeff,

I'm seeing these too. They all seem to be related to Christopher  
Lamb's

alignment changes. If he doesn't step up to fix soon, I'll revert the
changes.

Reid.

On Sat, 2007-04-21 at 07:30 -0700, Jeff Cohen wrote:
Commits in the last 12 hours or so have broken 34 regression tests  
and
caused 21 failure in llvm-test.  They appear to be concentrated in  
the

vector area.

___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits






___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-04-21 Thread Christopher Lamb

Blarg!

Sorry folks. First major commit and I missed regressions. Reverting  
was the right thing to do, sorry I wasn't up earlier.


--
Christopher Lamb

On Apr 21, 2007, at 12:21 PM, Reid Spencer wrote:


Jeff,

I'm seeing these too. They all seem to be related to Christopher  
Lamb's

alignment changes. If he doesn't step up to fix soon, I'll revert the
changes.

Reid.

On Sat, 2007-04-21 at 07:30 -0700, Jeff Cohen wrote:
Commits in the last 12 hours or so have broken 34 regression tests  
and
caused 21 failure in llvm-test.  They appear to be concentrated in  
the

vector area.

___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits






___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-04-21 Thread Reid Spencer
Jeff,

I'm seeing these too. They all seem to be related to Christopher Lamb's
alignment changes. If he doesn't step up to fix soon, I'll revert the
changes.

Reid.

On Sat, 2007-04-21 at 07:30 -0700, Jeff Cohen wrote:
> Commits in the last 12 hours or so have broken 34 regression tests and 
> caused 21 failure in llvm-test.  They appear to be concentrated in the 
> vector area.
> 
> ___
> llvm-commits mailing list
> llvm-commits@cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits

___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] Major regressions

2007-04-21 Thread Jeff Cohen
Commits in the last 12 hours or so have broken 34 regression tests and 
caused 21 failure in llvm-test.  They appear to be concentrated in the 
vector area.

___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-01-21 Thread Reid Spencer
Jeff,

On Sun, 2007-01-21 at 14:49 -0800, Jeff Cohen wrote:
> Chris Lattner wrote:
> >
> > On Jan 21, 2007, at 2:01 PM, Jeff Cohen wrote:
> >
> >> Well, I'm using the most recent version of both llvm and llvm-gcc
> >> (revision 254).  21 of the failures are ARM, but I don't care about
> >> those.  llvm-test is still running, but it's on track to matching the
> >> 275 failures I got the last time I ran it.
> >>
> >> I'm not going to switch to Linux or OS X or even 32-bit FreeBSD, and I'm
> >> not going to spend the time figuring out why LLVM hates 64-bit
> >> FreeBSD--especially as it's getting worse, not better--and it's clear no
> >> one else is going to spend the time either.  So I'm putting LLVM back on
> >> hold until later this year and hopefully the situation will be better 
> >> then.
> >
> > Fair enough.  However, unless *someone* on 64-bit freebsd 
> > investigates, it won't get better.  There is not much we can do about 
> > this.

FWIW, I agree with Chris on this. Someone on FreeBSD needs to do the
work. However, I'd be willing to take a crack at the obvious failures.
Most likely they are portability issues in the test cases. Could you
forward me the output of a nightly test run? I might be able to make a
dent in it.

Reid.

> >
> > -Chris
> >
> >
> True enough, but that someone will not be me.  I estimate that the work 
> required exceeds the benefits of me using LLVM.  The imbalance is far 
> worse on Windows.  And as if to prove the point, llvm-test has just 
> finished, with a record 287 failures.  So after fixing 5 of them, 
> another 12 have started failing.
> 

___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-01-21 Thread Anton Korobeynikov
Jeff, 

> True enough, but that someone will not be me.  I estimate that the work 
> required exceeds the benefits of me using LLVM.  The imbalance is far 
> worse on Windows.  And as if to prove the point, llvm-test has just 
> finished, with a record 287 failures.  So after fixing 5 of them, 
> another 12 have started failing.
llvm-test needs to be fixed for running on windows (at least for mingw32
flavour of llvm-gcc). Some time ago I posted big patch for llvm-test for
thuis. However, it was incomplete and should be rewritten. 

It's currently in my todo list, so, I hope to return to it soon...

-- 
With best regards, Anton Korobeynikov.

Faculty of Mathematics & Mechanics, Saint Petersburg State University.


___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-01-21 Thread Jeff Cohen
Chris Lattner wrote:
>
> On Jan 21, 2007, at 2:01 PM, Jeff Cohen wrote:
>
>> Well, I'm using the most recent version of both llvm and llvm-gcc
>> (revision 254).  21 of the failures are ARM, but I don't care about
>> those.  llvm-test is still running, but it's on track to matching the
>> 275 failures I got the last time I ran it.
>>
>> I'm not going to switch to Linux or OS X or even 32-bit FreeBSD, and I'm
>> not going to spend the time figuring out why LLVM hates 64-bit
>> FreeBSD--especially as it's getting worse, not better--and it's clear no
>> one else is going to spend the time either.  So I'm putting LLVM back on
>> hold until later this year and hopefully the situation will be better 
>> then.
>
> Fair enough.  However, unless *someone* on 64-bit freebsd 
> investigates, it won't get better.  There is not much we can do about 
> this.
>
> -Chris
>
>
True enough, but that someone will not be me.  I estimate that the work 
required exceeds the benefits of me using LLVM.  The imbalance is far 
worse on Windows.  And as if to prove the point, llvm-test has just 
finished, with a record 287 failures.  So after fixing 5 of them, 
another 12 have started failing.

___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-01-21 Thread Chris Lattner

On Jan 21, 2007, at 2:01 PM, Jeff Cohen wrote:

> Well, I'm using the most recent version of both llvm and llvm-gcc
> (revision 254).  21 of the failures are ARM, but I don't care about
> those.  llvm-test is still running, but it's on track to matching the
> 275 failures I got the last time I ran it.
>
> I'm not going to switch to Linux or OS X or even 32-bit FreeBSD,  
> and I'm
> not going to spend the time figuring out why LLVM hates 64-bit
> FreeBSD--especially as it's getting worse, not better--and it's  
> clear no
> one else is going to spend the time either.  So I'm putting LLVM  
> back on
> hold until later this year and hopefully the situation will be  
> better then.

Fair enough.  However, unless *someone* on 64-bit freebsd  
investigates, it won't get better.  There is not much we can do about  
this.

-Chris
___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-01-21 Thread Jeff Cohen
Well, I'm using the most recent version of both llvm and llvm-gcc 
(revision 254).  21 of the failures are ARM, but I don't care about 
those.  llvm-test is still running, but it's on track to matching the 
275 failures I got the last time I ran it.

I'm not going to switch to Linux or OS X or even 32-bit FreeBSD, and I'm 
not going to spend the time figuring out why LLVM hates 64-bit 
FreeBSD--especially as it's getting worse, not better--and it's clear no 
one else is going to spend the time either.  So I'm putting LLVM back on 
hold until later this year and hopefully the situation will be better then.

Reid Spencer wrote:
> On Sun, 2007-01-21 at 12:01 -0800, Jeff Cohen wrote:
>   
>> In the two weeks since I last ran them, the regression tests have gone 
>> from 4 to 63 unexpected failures.  Is this expected?
>> 
>
> No, TOT gives me 6 right now .. 5 in the new ARM backend (be patient)
> and 1 in the X86 backend.
>
>   
>> ___
>> llvm-commits mailing list
>> llvm-commits@cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>> 
>
>
>
>
>   

___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


Re: [llvm-commits] Major regressions

2007-01-21 Thread Reid Spencer
On Sun, 2007-01-21 at 12:01 -0800, Jeff Cohen wrote:
> In the two weeks since I last ran them, the regression tests have gone 
> from 4 to 63 unexpected failures.  Is this expected?

No, TOT gives me 6 right now .. 5 in the new ARM backend (be patient)
and 1 in the X86 backend.

> 
> ___
> llvm-commits mailing list
> llvm-commits@cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits

___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits


[llvm-commits] Major regressions

2007-01-21 Thread Jeff Cohen
In the two weeks since I last ran them, the regression tests have gone 
from 4 to 63 unexpected failures.  Is this expected?

___
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits