Opened 3 years ago

Closed 3 years ago

#5065 closed bug (fixed)

dph tests failing

Reported by: igloo Owned by: benl
Priority: high Milestone: 7.2.1
Component: Data Parallel Haskell Version: 7.1
Keywords: Cc: chak@…, benl@…
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: None/Unknown Difficulty:
Test Case: Blocked By:
Blocking: #5070 Related Tickets:

Description

These dph tests have been failing in validate for a while:

   dph-diophantine-fast(normal)
   dph-primespj-fast(normal)
   dph-quickhull-fast(normal)
   dph-words-fast(normal)

Change History (13)

comment:1 Changed 3 years ago by ezyang

  • Blocking 5070 added

comment:2 Changed 3 years ago by ezyang

The failure I'm getting is:

[1 of 2] Compiling PrimesVect       ( PrimesVect.hs, PrimesVect.o )
*** Vectorisation error ***
    Variable not vectorised: Control.Exception.Base.patError

So maybe a Core optimization pass isn't managing to eliminate the patError?

comment:3 Changed 3 years ago by simonpj

  • Cc chak@… benl@… added

I think Manuel is in mid-flight on some of this.

comment:4 Changed 3 years ago by rl

There should be no patErrors left after the gentle simplifier run which happens right before vectorisation. Has anything changed in the inlining behaviour of the gentle phase recently?

comment:5 Changed 3 years ago by simonpj

I don't know. Quite possibly. If there is some key invariant that must hold, we'd better be clear about what it is. I didn't know there was one.

Do let me know if that's the cause.

Simon

comment:6 Changed 3 years ago by rl

The problem is that since we don't vectorise the standard library yet, the vectoriser chokes on any calls to standard library functions. The desugarer introduces such calls (mostly to patError) even when they aren't necessary so we rely on gentle simplification to remove them before vectorising. This is indeed quite fragile but is only a temporary measure until we can vectorise the libraries.

I'll try to find out what exactly is happening there over the weekend.

comment:7 Changed 3 years ago by igloo

  • Milestone set to 7.2.1
  • Priority changed from normal to high

comment:8 Changed 3 years ago by igloo

  • Owner set to chak

I'm not sure which of the DPH people this should be assigned to, so please reassign if appropriate.

comment:9 Changed 3 years ago by benl

  • Owner changed from chak to benl

Send all DPH breakages to me.

comment:10 Changed 3 years ago by chak

Thanks, Ben, but some of these are due to my partial changes in the vectoriser and DPH libraries. They'll go away, once I'm done.

comment:11 Changed 3 years ago by chak

I fixed the problems related to my library changes. Two tests are still failing (albeit for different reasons). They are dph-diophantine-fast and dph-words-fast. The former produces a wrong result and the latter triggers an assertion in vectors slice function. To me, this looks like functional bugs in the library.

Ben, could you maybe have a look at this, or maybe get George to check the involved primitives.

comment:12 Changed 3 years ago by simonpj

Ben says: George is looking at this. He says it's something in the prim library. He has sent me patches but I'm querying him on them before committing.

comment:13 Changed 3 years ago by roldugin

  • Resolution set to fixed
  • Status changed from new to closed

Closed by commits

26c608a0c31d56917099e4f48bf58c1d1e92e61c
Fix dph-diophantine (#5065)

  1. Adjust array lengths to be equal when performing parallel array comprehensions
  2. Lower input arguments to prevent arithmetic overflow

6900c19dda729d22270f1831da9e351671a19bae
Fix dph-words. sliceP wants its second argument to be the slice length.

Note: See TracTickets for help on using tickets.