develooper Front page | perl.perl5.porters | Postings from November 2011

NWCLARK TPF grant report #11

From:
Nicholas Clark
Date:
November 25, 2011 13:55
Subject:
NWCLARK TPF grant report #11
Message ID:
20111125215507.GH37285@plum.flirble.org
[Hours]		[Activity]
2011/11/14	Monday
 1.50		RT #81332
 0.25		pod/buildtoc
 0.50		reading/responding to list mail
 4.00		stdbool.h
=====
 6.25

2011/11/15	Tuesday
 1.00		reading/responding to list mail
 2.25		stdbool.h
 1.00		t/test.pl
=====
 4.25

2011/11/16	Wednesday
 0.50		stdbool.h
=====
 0.50

2011/11/17	Thursday
 0.50		bisect.pl (fatal build regression)
 1.50		bisect.pl (feedback from Ricardo)
 3.75		reading/responding to list mail
=====
 5.75

2011/11/18	Friday
 0.25		RT #103006
 2.00		bisect.pl (fixing parallel make bugs)
 1.00		perltodo
 0.50		pod/buildtoc
 1.25		reading/responding to list mail
 0.75		release process
=====
 5.75

2011/11/20	Sunday
 2.25		bisect.pl (fixing parallel make bugs)
=====
 2.25

Which I calculate is 24.75 hours

An uneventful week, but we did finally get to the bottom of the AIX
stdbool.h problem. It turned out to be a bug in xlc, which caused it to
generate bad code. Worked around with this:


commit 18f5643bfee3e4c35fe1b510ad2e37dcb28b9efc
Author: Nicholas Clark <nick@ccl4.org>
Date:   Tue Nov 15 19:44:18 2011 +0100

    Tweak the cBOOL() macro to avoid problems with the AIX compiler.
    (cherry picked from commit 0cebf65582f924952bfee1472749d442d51e43e6)

diff --git a/handy.h b/handy.h
index 2c2311a..8777644 100644
--- a/handy.h
+++ b/handy.h
@@ -115,9 +115,10 @@ Null SV pointer. (No longer available when C<PERL_CORE> is defined.)
 
 /* a simple (bool) cast may not do the right thing: if bool is defined
  * as char for example, then the cast from int is implementation-defined
+ * (bool)!!(cbool) in a ternary triggers a bug in xlc on AIX
  */
 
-#define cBOOL(cbool) ((bool)!!(cbool))
+#define cBOOL(cbool) ((cbool) ? (bool)1 : (bool)0)
 
 /* Try to figure out __func__ or __FUNCTION__ equivalent, if any.
  * XXX Should really be a Configure probe, with HAS__FUNCTION__
 

Nicholas Clark



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About