public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
* xfsprogs: to -DDEBUG or not to -DDEBUG?
@ 2010-02-04 16:53 Eric Sandeen
  2010-02-05  2:31 ` Dave Chinner
  0 siblings, 1 reply; 3+ messages in thread
From: Eric Sandeen @ 2010-02-04 16:53 UTC (permalink / raw)
  To: xfs mailing list

Fedora, long ago, disabled debug in the xfsprogs specfile:

http://cvs.fedoraproject.org/viewvc/F-12/xfsprogs/xfsprogs.spec?r1=1.5&r2=1.6

* Wed Apr 20 2005 Dave Jones <davej@redhat.com>
- Disable debug. (#151438)

per this bug:  https://bugzilla.redhat.com/show_bug.cgi?id=151438

referencing this email thread:

http://oss.sgi.com/archives/linux-xfs/2005-03/msg00038.html
which no longer exists (grrrr) but is probably now here:

http://oss.sgi.com/archives/xfs/2005-03/msg00416.html

Fedora still builds with -DNDEBUG, but the upstream tarball has
it on by default.  I have seen several occasions where other
distros had failing xfs_repairs which were "fixed" by disabling
debug.  I'd like to make a decision on whether DEBUG should be
on or off by default for upstream releases.  Any thoughts?

Thanks,
-Eric

_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: xfsprogs: to -DDEBUG or not to -DDEBUG?
  2010-02-04 16:53 xfsprogs: to -DDEBUG or not to -DDEBUG? Eric Sandeen
@ 2010-02-05  2:31 ` Dave Chinner
  2010-02-05 21:14   ` Eric Sandeen
  0 siblings, 1 reply; 3+ messages in thread
From: Dave Chinner @ 2010-02-05  2:31 UTC (permalink / raw)
  To: Eric Sandeen; +Cc: xfs mailing list

On Thu, Feb 04, 2010 at 10:53:23AM -0600, Eric Sandeen wrote:
> Fedora, long ago, disabled debug in the xfsprogs specfile:
> 
> http://cvs.fedoraproject.org/viewvc/F-12/xfsprogs/xfsprogs.spec?r1=1.5&r2=1.6
> 
> * Wed Apr 20 2005 Dave Jones <davej@redhat.com>
> - Disable debug. (#151438)
> 
> per this bug:  https://bugzilla.redhat.com/show_bug.cgi?id=151438
> 
> referencing this email thread:
> 
> http://oss.sgi.com/archives/linux-xfs/2005-03/msg00038.html
> which no longer exists (grrrr) but is probably now here:
> 
> http://oss.sgi.com/archives/xfs/2005-03/msg00416.html
> 
> Fedora still builds with -DNDEBUG, but the upstream tarball has
> it on by default.  I have seen several occasions where other
> distros had failing xfs_repairs which were "fixed" by disabling
> debug.  I'd like to make a decision on whether DEBUG should be
> on or off by default for upstream releases.  Any thoughts?

Personally I'd prefer the repair process to stop if it comes across
inconsistencies it can't handle. Ignoring them is as likely to "fix"
the crash as it is to corrupt the filesystem more.

On top of that we get bug reports when those problems are hit so
we can look into what caused the problem. We don't really have a
repair test suite that covers all the possible corruptions that
can occur, so we are kind of reliant on users reporting conditions
we've never had to handle before so we can fix them...

Cheers,

Dave.
-- 
Dave Chinner
david@fromorbit.com

_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: xfsprogs: to -DDEBUG or not to -DDEBUG?
  2010-02-05  2:31 ` Dave Chinner
@ 2010-02-05 21:14   ` Eric Sandeen
  0 siblings, 0 replies; 3+ messages in thread
From: Eric Sandeen @ 2010-02-05 21:14 UTC (permalink / raw)
  To: Dave Chinner; +Cc: xfs mailing list

Dave Chinner wrote:
> On Thu, Feb 04, 2010 at 10:53:23AM -0600, Eric Sandeen wrote:
>> Fedora, long ago, disabled debug in the xfsprogs specfile:
>>
>> http://cvs.fedoraproject.org/viewvc/F-12/xfsprogs/xfsprogs.spec?r1=1.5&r2=1.6
>>
>> * Wed Apr 20 2005 Dave Jones <davej@redhat.com>
>> - Disable debug. (#151438)
>>
>> per this bug:  https://bugzilla.redhat.com/show_bug.cgi?id=151438
>>
>> referencing this email thread:
>>
>> http://oss.sgi.com/archives/linux-xfs/2005-03/msg00038.html
>> which no longer exists (grrrr) but is probably now here:
>>
>> http://oss.sgi.com/archives/xfs/2005-03/msg00416.html
>>
>> Fedora still builds with -DNDEBUG, but the upstream tarball has
>> it on by default.  I have seen several occasions where other
>> distros had failing xfs_repairs which were "fixed" by disabling
>> debug.  I'd like to make a decision on whether DEBUG should be
>> on or off by default for upstream releases.  Any thoughts?
> 
> Personally I'd prefer the repair process to stop if it comes across
> inconsistencies it can't handle. Ignoring them is as likely to "fix"
> the crash as it is to corrupt the filesystem more.
> 
> On top of that we get bug reports when those problems are hit so
> we can look into what caused the problem. We don't really have a
> repair test suite that covers all the possible corruptions that
> can occur, so we are kind of reliant on users reporting conditions
> we've never had to handle before so we can fix them...
> 
> Cheers,
> 
> Dave.

Hrm.  Well, that makes sense.

OTOH, Debian turns it off too:

$ grep DEBUG debian/rules 
options = export DEBUG=-DNDEBUG DISTRIBUTION=debian \

and for some reason when I take this out of the Fedora specfile,
it fails to build because:

xfs_bmap.c:23: warning: 'xfs_bmap_check_leaf_extents' used but never defined

and indeed there is a forward declaration:

#ifdef DEBUG
STATIC void
xfs_bmap_check_leaf_extents(xfs_btree_cur_t *cur, xfs_inode_t *ip, int whichfork);
#endif

but no definition that I can find ....

Something must be odd w/ the way this flag works though because a simple "make"
in the git tree, w/o any -DNDEBUG, works fine for me ...

Meanwhile I'm leaving DEBUG=-DNDEBUG on in Fedora just for now :)

-Eric

_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-02-05 21:13 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-04 16:53 xfsprogs: to -DDEBUG or not to -DDEBUG? Eric Sandeen
2010-02-05  2:31 ` Dave Chinner
2010-02-05 21:14   ` Eric Sandeen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox