Ticket #4049 (accepted enhancement)

Opened 8 years ago

Last modified 7 years ago

Improve error reporting in read_matrix_market() and read_dimacs()

Reported by: gemacke Owned by: gemacke
Priority: normal Milestone: 1.2
Version: 1.0 Severity: minor
Keywords: Cc:

Description (last modified by gemacke) (diff)

This ticket assumes responsibility for unfinished work in #3981.

The functions read_matrix_market() and read_dimacs() report errors in the main loops that parse the text by printing an error message and calling exit(). I did this originally because it parallelized okay and still gave the user error feedback. However, this doesn't fit in with the spirit of the read_* functions returning a boolean to indicate an error. Changing the way this is done may also improve performance of the loops.

One possibility is to keep an error buffer and an error count. When an iteration encounters an error, it could increment the error count. If the returned value of the increment is 0, that thread would copy its error message to the buffer. That way there would be no loop exits inside the loops. After the loops, print out the error message and return false if the error count is greater than 0.

This method needs to be tested to see how it parallelizes. It needs to pass canal and have the same or better performance in tests. If this doesn't work, then some other method needs to be used.

Change History

comment:1 Changed 8 years ago by gemacke

  • Status changed from new to accepted

comment:2 Changed 8 years ago by gemacke

  • Description modified (diff)

comment:3 Changed 7 years ago by gemacke

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

Addressed in r3604.

comment:4 Changed 7 years ago by gemacke

  • Status changed from closed to reopened
  • Resolution fixed deleted

Okay. I accidentally closed the wrong ticket for revision 3604. Reopening.

comment:5 Changed 7 years ago by gemacke

  • Status changed from reopened to accepted

comment:6 Changed 7 years ago by gemacke

  • Milestone changed from 1.1 to 1.2
Note: See TracTickets for help on using tickets.