Re: new egg: pkg-config

2022-04-08 Thread Chris Brannon
Mario Domenech Goulart  writes:

> Hi Chris,
>
> Thanks!
>
> Tests fail here.  Maybe a bug in tests?

Hi Mario,
It is an environment difference I overlooked.  There are at least two
implementations of pkg-config: the reference one and pkgconf.  The
reference implementation appears to implicitly insert -L/usr/lib in
--static --libs output, but pkgconf does not.  Locally I use pkgconf, so
I didn't catch this.

I tagged 0.1.1 with fixed tests.

Thanks,
-- Chris



Re: new egg: pkg-config

2022-04-08 Thread Mario Domenech Goulart
Hi Chris,

On Fri, 08 Apr 2022 03:18:14 -0700 Chris Brannon  wrote:

> I had a need for this.  It's kind of trivial; I hope others find it
> useful.
>
> The release-info file is here:
> https://the-brannons.com/cgit/cgit.cgi/chicken-pkg-config/plain/pkg-config.release-info

Thanks!

Tests fail here.  Maybe a bug in tests?

pkg-config static libs happy path  [ FAIL]
expected ("-L/usr/local/lib" "-lcurl" "-lnghttp2" "-lssl" "-lcrypto" 
"-L/usr/lib" "-lgssapi" "-lgssapi_krb5" "-lheimntlm" "-lkrb5" "-lhx509" 
"-lcom_err" "-lcrypto" "-l
asn1" "-lwind" "-lheimbase" "-lroken" "-lcrypt" "-pthread" "-lz" "-lkrb5" 
"-lgssapi" "-lgssapi_krb5" "-lkrb5" "-lgssapi" "-lgssapi_krb5" 
"-L/usr/local/lib" "-pthread") but
 got ("-L/usr/local/lib" "-lcurl" "-lnghttp2" "-lssl" "-lcrypto" "-lgssapi" 
"-lgssapi_krb5" "-lheimntlm" "-lkrb5" "-lhx509" "-lcom_err" "-lcrypto" "-lasn1" 
"-lwind" "-lhei
mbase" "-lroken" "-lcrypt" "-pthread" "-lz" "-lkrb5" "-lgssapi" "-lgssapi_krb5" 
"-lkrb5" "-lgssapi" "-lgssapi_krb5" "-pthread")
(pkg-config:libs "libcurl" #:static #t)

All the best.
Mario
-- 
http://parenteses.org/mario



Re: Performance question concerning chicken flonum vs "foreign flonum"

2022-04-08 Thread Christian Himpe


Christian Himpe schrieb am 2021-11-07:

> felix.winkelm...@bevuta.com schrieb am 2021-11-07:
> > > Dear Felix,
> > >
> > > Thank you for the patch. I built the current git head with your patch.
> > > After importing chicken.flonum, I get the following error when calling 
> > > fp*+:
> > >

> > I'm terribly sorry. I'm an ass, I didn't even test it in the interpreter. 
> > Please
> > find attached a revised patch.


> > felix

> Dear felix,

> the latest patch works. I extended my test code and here are the results:

> without -C -mfma:

> csc -O5 -d0 -C -O3 fma-test.scm && ./fma-test
> 7.998s CPU time, 0/225861 GCs (major/minor), maximum live heap: 30.78 MiB
> 10.104s CPU time, 0/256410 GCs (major/minor), maximum live heap: 30.78 MiB
> 10.69s CPU time, 0/311364 GCs (major/minor), maximum live heap: 30.78 MiB

> with -C -mfma:

> csc -O5 -d0 -C -O3 -C -mfma fma-test.scm && ./fma-test
> 7.697s CPU time, 0/238095 GCs (major/minor), maximum live heap: 30.78 MiB
> 9.135s CPU time, 0/262467 GCs (major/minor), maximum live heap: 30.78 MiB
> 11.008s CPU time, 0/317460 GCs (major/minor), maximum live heap: 30.78 MiB

> It seems the number of GCs is a lot higher than for fp*/fp+ or c99-fma with 
> or without fma compiler flag. So currently, there seems to be no benefit 
> integrating c99's fma as fp*+ besides a slightly better rounding error. At 
> least for me, this comes unexpected.

> Thank you for providing the patch. If you want to test something in this 
> regard in the future, I am happy to test further patches.

> Cheers

> Christian

Dear felix,

after coming back to this function and the associated issues regularly, I 
revised my opinion on integrating"fp+*" into (chicken flonum), given it uses 
the C99-fma function. On the one hand, this operation is so fundamental in 
numerical computations that it warrants a specialized function, on the other 
hand the (somewhat) improved rounding could help a little. Finally, Gauche ( 
https://practical-scheme.net/gauche/man/gauche-refe/R7RS-large.html#index-fl_002b_002a
 ) and MIT Scheme ( 
https://www.gnu.org/software/mit-scheme/documentation/stable/mit-scheme-ref.html#Flonum-Operations
 ) provide this functionality. All in all, I would really appreciate if an 
inclusion of a fma-based "fp+*" function into the (chicken flonum) module could 
be considered in future versions of CHICKEN Scheme. Maybe your provided patch 
reduces the effort for this.

Thank you very much

Christian 



new egg: pkg-config

2022-04-08 Thread Chris Brannon
I had a need for this.  It's kind of trivial; I hope others find it
useful.

The release-info file is here:
https://the-brannons.com/cgit/cgit.cgi/chicken-pkg-config/plain/pkg-config.release-info

-- Chris