Re: Battle-plan for CTFE

2016-07-29 Thread Stefan Koch via Digitalmars-d-announce

On Friday, 29 July 2016 at 14:28:03 UTC, Stefan Koch wrote:


if ((a && b) || (a && c)) {//bla}


This is now solved although quite naively at the cost of 
inserting twice the number of instructions for thoose cases.

Then agian we are still much faster then the old interpreter.
And I can still optimize this if it should turn out to be a 
bottleneck.


Tomorrow I will fix the regressed string handling.


Re: New Diet template engine almost complete, ready for comments

2016-07-29 Thread Sönke Ludwig via Digitalmars-d-announce

Am 29.07.2016 um 13:28 schrieb Chris:

Talking about diets, will reShop[1] be available for Android an iOS too?
You could extend it by adding "health tips" (add fruit & veg
automatically), a calorie counter (for single items and the whole list) ;)

http://rejectedsoftware.com/products/reshop


Yeah, diet/health tips are always a hot topic, I think we even talked 
about something like that at some point ;)


Porting it to those platforms was the initial idea. But since both BB10 
and WP are more or less dead now, the main feature of providing full 
cross-platform synchronization of the lists became a moot point (there 
are plenty of solutions for Android/iOS already). And then it also 
really was just a little test project anyway.




Re: D-Man culture

2016-07-29 Thread Chris via Digitalmars-d-announce

On Thursday, 28 July 2016 at 16:10:58 UTC, Seb wrote:
we could generate revenue with the (real) D-Man? I
don't know, if it existed independently of DLang, or if it's 
in some way related to DLang. In the latter case we might use 
it to make some money for the D Foundation.


@Chris you should get in touch with the nice guys from 
Sociomantic (e.g.
Dylan Cromwell (https://github.com/dylan-cromwell-sociomantic) 
and Leandro Lucarella 
(https://github.com/leandro-lucarella-sociomantic)). They are 
working on helping the D Foundation to setup a D Store with 
swag ;-)


Will they sell D-shirts as well (couldn't resist the pun!).


Re: Terminix Stable 1.2.0 Released

2016-07-29 Thread David Nadlinger via Digitalmars-d-announce

On Saturday, 23 July 2016 at 14:24:08 UTC, Matthias Klumpp wrote:
4) Resolving weird LDC bugs like this one: 
https://github.com/ldc-developers/ldc/issues/1618 - might 
actually be an LLVM issue, but I don't know enough to pin down 
the issue.


Turns out that this is not actually a LDC/LLVM bug, but an 
artefact of Ubuntu 16.10 patching GCC to generate 
position-independent executables by default.


Is DMD also affected by this? Does anybody know how other 
languages are dealing with the change?


 — David


Re: simple sax-style xml parser

2016-07-29 Thread ketmar via Digitalmars-d-announce

On Friday, 29 July 2016 at 14:47:08 UTC, Chris wrote:
Thanks. I might actually use it. I need an XML parser and wrote 
a very basic and incomplete one for my needs.


great. don't forget to get lastest versions from that links. and 
feel free to report any bugs here, i'll try to fix them asap. ;-)


Re: simple sax-style xml parser

2016-07-29 Thread Chris via Digitalmars-d-announce

On Wednesday, 20 July 2016 at 01:49:37 UTC, ketmar wrote:
i wrote a simple sax-style xml parser[1][2] for my own needs, 
and decided to share it. it has two interfaces: `xmparse()` 
function which simply calls callbacks without any validation or 
encoding conversion, and `SaxyEx` class, which does some 
validation, converts content to utf-8 (from anything 
std.encoding supports), and calls callbacks when the given path 
is triggered.


it can parse any `char` input range, or std.stdio.File. parsing 
files is probably slightly faster than parsing ranges.


internally it is extensively reusing memory buffers it 
allocated, so it should not create a big pressure on GC.


you are expected to copy any data you need in callbacks (not 
just slice, but .dup!).


so far i'm using it to parse fb2 files, and it parsing 8.5 
megabyte utf-8 file (and creating internal reader structures, 
including splitting text to words and some other housekeeping) 
in one second on my i3 (with dmd -O, even without -inline and 
-release).


it is not really documented, but i think it is "intuitive". 
there are also some comments in source code; please, read 
those! ;-)


p.s. it decodes standard xml entities (&# and &#x probably 
works right only in utf-8 files, though), understands CDATA and 
comments.



enjoy, and happy hacking!


[1] http://repo.or.cz/iv.d.git/blob_plain/HEAD:/saxy.d
[2] http://repo.or.cz/iv.d.git/tree/HEAD:/saxytests


Thanks. I might actually use it. I need an XML parser and wrote a 
very basic and incomplete one for my needs.


Re: Battle-plan for CTFE

2016-07-29 Thread Stefan Koch via Digitalmars-d-announce
On Friday, 29 July 2016 at 12:47:55 UTC, Robert burner Schadek 
wrote:

On Friday, 29 July 2016 at 11:30:20 UTC, Stefan Koch wrote:

please share your thoughts.


When is this moving into dmd master?


As soon as it passes the test-suite.
And can execute diet-ng on the fast-path.

Currently I have issues with chained binary expressions.
such as

if ((a && b) || (a && c)) {//bla}



Re: Battle-plan for CTFE

2016-07-29 Thread Stefan Koch via Digitalmars-d-announce

On Friday, 29 July 2016 at 13:07:12 UTC, Edwin van Leeuwen wrote:

On Friday, 29 July 2016 at 11:30:20 UTC, Stefan Koch wrote:

I have fresh performance statistics:


Is there any improvement in memory usage?


Yes!
There memory usage is the same as run-time execution.
plus about 16k for the interpreter state.




Re: Battle-plan for CTFE

2016-07-29 Thread Edwin van Leeuwen via Digitalmars-d-announce

On Friday, 29 July 2016 at 11:30:20 UTC, Stefan Koch wrote:

I have fresh performance statistics:


Is there any improvement in memory usage?



Re: Battle-plan for CTFE

2016-07-29 Thread Robert burner Schadek via Digitalmars-d-announce

On Friday, 29 July 2016 at 11:30:20 UTC, Stefan Koch wrote:

please share your thoughts.


When is this moving into dmd master?


From the D Blog: Martin Nowak on the DMD release process

2016-07-29 Thread Mike Parker via Digitalmars-d-announce
It was time for another Core Team Update on the D Blog. This time 
around, Martin Nowak shares how he got involved with the DMD 
release process and where you can learn more about it. The post 
is at [1] and the reddit thread at [2].


Now that Vladimir and Martin have gotten their updates out of the 
way, I foresee some prodding, cajoling and arm twisting in my 
future for the next couple :)


[1] 
https://dlang.org/blog/2016/07/29/core-team-update-martin-nowak/
[2] 
https://www.reddit.com/r/programming/comments/4v68ty/from_the_d_blog_martin_nowak_on_the_dmd_release/


Re: Battle-plan for CTFE

2016-07-29 Thread Stefan Koch via Digitalmars-d-announce

Hi,

I have fresh performance statistics:
The test[1] involved running an empty while loop.

Machine 1 Linux :
DMD release : Interpreted : 3400 ms || Pseudo-Jited 230 || 50ms 
Native
DMD Debug : Interpreted 4560 || Pseudo-Jited 260ms || Native 230 
ms


LDC release : Interpreted 2400 ms || Pseudo-Jited 0 ms || Native 
0 ms
LDC debug : Interpreted 8700 ms || Pseudo-Jited 330 ms || Native 
250 ms


Machine 2 Windows :

DMD release : Interpreted : 5500 ms || Pseudo-Jited 180ms || 40ms 
Native
DMD Debug : Interpreted 5500 || Pseudo-Jited 320ms || Native 180 
ms



Pay attention to the ratio (~4.5) between (pseudo)jit[2] and 
native.

This slowdown inherent in the VM design I choose.

please share your thoughts.

[1] https://github.com/UplinkCoder/dmd/blob/newCTFE/bcPerf.d
[2] 
https://github.com/UplinkCoder/dmd/blob/newCTFE/src/bc_c_backend.d


Re: New Diet template engine almost complete, ready for comments

2016-07-29 Thread Chris via Digitalmars-d-announce
Talking about diets, will reShop[1] be available for Android an 
iOS too? You could extend it by adding "health tips" (add fruit & 
veg automatically), a calorie counter (for single items and the 
whole list) ;)


http://rejectedsoftware.com/products/reshop


Re: The D Language Foundation has filed for non-profit status

2016-07-29 Thread Chris via Digitalmars-d-announce
On Thursday, 21 July 2016 at 02:16:55 UTC, Andrei Alexandrescu 
wrote:

Hello everyone,


Effective today the IRS has received the application of The D 
Language Foundation for tax-exempt (non-profit) status. An 
attorney and an accountant have helped me with the application. 
Going forward, they will work with us on a need basis.


Following the next few months we have an odd "limbo" status. 
After that (most likely before the end of this year) we will 
get a decision (or more questions) from the IRS.


This is an important milestone for the Foundation and for the D 
language development. The tax-exempt status will allow the 
Foundation to receive tax-advantageous donations from other 
organizations, and to fully use funds for the development of 
the language.


By the Foundation bylaws we defined, the officers of the 
Foundation (Walter, Ali, and myself) are not allowed to receive 
payment for their work on the Foundation.


Many thanks to our wonderful grass-roots and corporate 
community that has been ever so constructive and supportive in 
this endeavor.



Andrei


o   o
|\
 \ ___   /
  |,-oo\\
  ||||
  ||||
  ||   //
  ||__//
  '---
   \  \
   /  /
   ^  ^