Re: update.sh

2012-01-16 Thread Andrei Alexandrescu
On 1/16/12 1:18 AM, Jacob Carlborg wrote: On 2012-01-16 06:20, Nick Sabalausky wrote: Andrei Alexandrescuseewebsiteforem...@erdani.org wrote in message news:jevr6q$8vp$1...@digitalmars.com... I just added a handy script, tools/update.sh.

Re: A tutorial on D templates

2012-01-16 Thread Ali Çehreli
On 01/15/2012 04:34 PM, Andrei Alexandrescu wrote: On 1/15/12 4:19 PM, Philippe Sigaud wrote: On Sun, Jan 15, 2012 at 17:00, Ali Çehreliacehr...@yahoo.com wrote: I do think a big range tutorial is overdue. Andrei's article is good, but we need something a bit more detailed / for newbies I

Re: update.sh

2012-01-16 Thread Nick Sabalausky
Andrei Alexandrescu seewebsiteforem...@erdani.org wrote in message news:jf0l94$1i6a$1...@digitalmars.com... On 1/16/12 1:18 AM, Jacob Carlborg wrote: On 2012-01-16 06:20, Nick Sabalausky wrote: Soo...you made a tool to do what DVM already does? ;) And only works on Posix. It's a simple

Re: update.sh

2012-01-16 Thread Jacob Carlborg
On 2012-01-16 08:57, Andrei Alexandrescu wrote: On 1/16/12 1:18 AM, Jacob Carlborg wrote: On 2012-01-16 06:20, Nick Sabalausky wrote: Andrei Alexandrescuseewebsiteforem...@erdani.org wrote in message news:jevr6q$8vp$1...@digitalmars.com... I just added a handy script, tools/update.sh.

Re: update.sh

2012-01-16 Thread Jacob Carlborg
On 2012-01-16 10:02, Jacob Carlborg wrote: On 2012-01-16 08:57, Andrei Alexandrescu wrote: On 1/16/12 1:18 AM, Jacob Carlborg wrote: On 2012-01-16 06:20, Nick Sabalausky wrote: Andrei Alexandrescuseewebsiteforem...@erdani.org wrote in message news:jevr6q$8vp$1...@digitalmars.com... I just

Re: A tutorial on D templates

2012-01-16 Thread Andrej Mitrovic
On 1/15/12, Jacob Carlborg d...@me.com wrote: I'm not completely sure how it works but it looks like that Fields mixin can be replace with the code you have referenced from my Orange library and opDispatch. You mean your `fieldsOf` template? I'm not really sure how that would work, I've tried

Re: update.sh

2012-01-16 Thread Nick Sabalausky
Nick Sabalausky a@a.a wrote in message news:jf0ois$1t01$1...@digitalmars.com... Andrei Alexandrescu seewebsiteforem...@erdani.org wrote in message news:jf0l94$1i6a$1...@digitalmars.com... On 1/16/12 1:18 AM, Jacob Carlborg wrote: On 2012-01-16 06:20, Nick Sabalausky wrote: Soo...you made a

Re: update.sh

2012-01-16 Thread Jesse Phillips
On Monday, 16 January 2012 at 04:16:12 UTC, Andrei Alexandrescu wrote: On 1/15/12 9:15 PM, Jesse Phillips wrote: I might suggest using: git clone -o upstream git://github.com/D-Programming-Language/tools.git for cloning a new repository. This would allow developers to add their fork of the

Re: update.sh

2012-01-16 Thread Andrei Alexandrescu
On 1/16/12 3:02 AM, Jacob Carlborg wrote: A large list of dependencies?? The only runtime dependency is zlib. That's in the case we want to include it in tools/. Andrei

Re: update.sh

2012-01-16 Thread Jacob Carlborg
On 2012-01-16 16:38, Andrei Alexandrescu wrote: On 1/16/12 3:02 AM, Jacob Carlborg wrote: A large list of dependencies?? The only runtime dependency is zlib. That's in the case we want to include it in tools/. Andrei So you're referring to the build dependencies. * DSSS - It's possible

Re: update.sh

2012-01-16 Thread Andrei Alexandrescu
On 1/16/12 5:46 AM, Nick Sabalausky wrote: I don't mean to say that your tool is bad or that you shouldn't have made it, but the issues you addressed with DVM can be fixed, and really, I've been detecting a bit of NIH coming from your general direction. I've noticed that any time you want

Re: DMD 2.x compiler in Arch Linux repo

2012-01-16 Thread Jordi Sayol
Al 15/01/12 23:57, En/na Jordi Sayol ha escrit: Al 15/01/12 23:16, En/na Михаил Страшун ha escrit: http://www.archlinux.org/packages/?q=dmd Since today 2.x branch of dmd is in Arch Linux [community] repo, replacing 1.x branch. Very good news! It works like a charm. Congratulations!

Re: DMD 2.x compiler in Arch Linux repo

2012-01-16 Thread Михаил Страшун
It looks like there is a misunderstanding here - I am not a maintainer of this package in Arch repo. https://wiki.archlinux.org/index.php/User:Svenstaro is. Any improvement proposals should be sent to him, I suppose. For now it looks like he have just taken dmd2 AUR package I have been

Re: update.sh

2012-01-16 Thread jdrewsen
On Monday, 16 January 2012 at 15:48:17 UTC, Jacob Carlborg wrote: On 2012-01-16 16:38, Andrei Alexandrescu wrote: On 1/16/12 3:02 AM, Jacob Carlborg wrote: A large list of dependencies?? The only runtime dependency is zlib. That's in the case we want to include it in tools/. Andrei So

Re: A tutorial on D templates

2012-01-16 Thread Jacob Carlborg
On 2012-01-16 12:43, Andrej Mitrovic wrote: On 1/15/12, Jacob Carlborgd...@me.com wrote: I'm not completely sure how it works but it looks like that Fields mixin can be replace with the code you have referenced from my Orange library and opDispatch. You mean your `fieldsOf` template? I'm not

Re: DMD 2.x compiler in Arch Linux repo

2012-01-16 Thread Andrei Alexandrescu
On 1/16/12 2:05 PM, Михаил Страшун wrote: Are there any negative consequences of doing this? :) Sorry, I know close to nothing about reddit. The news must be noteworthy. My question is basically Is this an interesting piece of news, or something minor? Andrei

Re: DMD 2.x compiler in Arch Linux repo

2012-01-16 Thread Bernard Helyer
On Monday, 16 January 2012 at 23:53:54 UTC, Andrei Alexandrescu wrote: On 1/16/12 2:05 PM, Михаил Страшун wrote: Are there any negative consequences of doing this? :) Sorry, I know close to nothing about reddit. The news must be noteworthy. My question is basically Is this an interesting

Re: A tutorial on D templates

2012-01-16 Thread Nick Sabalausky
Walter Bright newshou...@digitalmars.com wrote in message news:jet0kk$1h97$1...@digitalmars.com... On 1/14/2012 1:00 PM, Nick Sabalausky wrote: Walter Brightnewshou...@digitalmars.com wrote in message news:jesl4i$30v3$1...@digitalmars.com... You and I are going to disagree on this.

Re: A tutorial on D templates

2012-01-16 Thread Nick Sabalausky
dennis luehring dl.so...@gmx.net wrote in message news:jeu3mf$94o$1...@digitalmars.com... https://github.com/PhilippeSigaud/D-templates-tutorial/blob/master/dtemplates.pdf ...with acrobat reader... Eewww. Do youself a favor and grab a copy of FoxIt Reader. Works just as well, but isn't an

DuckFuck v0.2: D-based FuckFuck and More! (Such as BrainFuck)

2012-01-16 Thread Nick Sabalausky
(I've put far too much effort into this... ;) ) Introducing DuckFuck: ( http://bitbucket.org/Abscissa/duckfuck ) A flexible, modular D-based interpreter/conversion system for FuckFuck and other BrainFuck-based langauges. Includes the DuckFucker: A command-line tool to interpret any supported

Re: __declspec(dllexport)

2012-01-16 Thread Adam Wilson
On Sun, 15 Jan 2012 19:26:38 -0800, Peter Lindener lindener.pe...@gmail.com wrote: D2 is Great, I've got D based numeric array DLLs extending Python Numpy.. My Question is: What is the D2 language's equivalent for __declspec(dllexport).. Can one export variables as well as functions from a

Re: Biggest Issue with D - Definition and Versioning

2012-01-16 Thread Gour
On Sun, 15 Jan 2012 18:23:38 -0600 Andrei Alexandrescu seewebsiteforem...@erdani.org wrote: Again: if D is a hobby we have, all's great. Otherwise, we must show people that we are serious about finishing the core language implementation, that we make promises that we are able to keep, and

Re: Biggest Issue with D - Definition and Versioning

2012-01-16 Thread Gour
On Sun, 15 Jan 2012 15:57:27 -0500 Nick Sabalausky a@a.a wrote: It doesn't matter if *you've* identified game dev as a market you care about: D *is already* a gamedev language. And gamedev is already an *ideal* audience for D to target. Then it would be nice if the gamedev industry could

No, that is not right

2012-01-16 Thread Bee
It isn't.

Re: SIMD benchmark

2012-01-16 Thread Andre Tampubolon
I just built 32 64 bit DMD (latest commit on git tree is f800f6e342e2d9ab1ec9a6275b8239463aa1cee8) Using the 32-bit version, I got this error: Internal error: backend/cg87.c 1702 The 64-bit version went fine. Previously, both 32 and 64 bit version had no problem. On 01/15/2012 01:56 PM,

Re: SIMD benchmark

2012-01-16 Thread Walter Bright
On 1/16/2012 12:59 AM, Andre Tampubolon wrote: I just built 32 64 bit DMD (latest commit on git tree is f800f6e342e2d9ab1ec9a6275b8239463aa1cee8) Using the 32-bit version, I got this error: Internal error: backend/cg87.c 1702 The 64-bit version went fine. Previously, both 32 and 64 bit

Re: Biggest Issue with D - Definition and Versioning

2012-01-16 Thread Russel Winder
On Mon, 2012-01-16 at 09:03 +0100, Gour wrote: [...] Then it would be nice if the gamedev industry could identify D as gamedev language as well and pour some $s, €s...to support/speed up development, but I wonder why it does not happen. ;) devils-advocate The games industry works with C, C++,

Re: Biggest Issue with D - Definition and Versioning

2012-01-16 Thread Paulo Pinto
With smaller startups moving to Unity/C#, XNA for XBox 360/Windows/WP7 and Sony now supporting Mono/C# as the main development environment for the VITA and PlaySuite, it might already be too late for D in the gaming world. There are already quite a few iPhone major game titles that are

Re: SIMD benchmark

2012-01-16 Thread Andre Tampubolon
Well I only have 1 machine, a laptop running 64 bit Arch Linux. Yesterday I did a git pull, built both 32 64 bit DMD, and this code compiled fine using those. But now, the 32 bit version fails. Walter Bright newshou...@digitalmars.com wrote: On 1/16/2012 12:59 AM, Andre Tampubolon wrote: I

Re: version()

2012-01-16 Thread Marco Leise
Am 16.01.2012, 08:25 Uhr, schrieb Manu turkey...@gmail.com: On 16 January 2012 02:37, Jonathan M Davis jmdavisp...@gmx.com wrote: On Monday, January 16, 2012 02:16:03 Manu wrote: As for version(linux || OSX) you can use version(Posix) It'll include FreeBSD as well, but then

Re: SIMD benchmark

2012-01-16 Thread Walter Bright
32 bit SIMD for Linux is not implemented. It's all 64 bit platforms, and 32 bit OS X. On 1/16/2012 2:35 AM, Andre Tampubolon wrote: Well I only have 1 machine, a laptop running 64 bit Arch Linux. Yesterday I did a git pull, built both 32 64 bit DMD, and this code compiled fine using those.

I was going to go to sleep

2012-01-16 Thread Bee
I really do hate you.

wait

2012-01-16 Thread Bee
I wanted to say that I don't, ut I do. And with my limited experience and vast knowledge would I tell you that yep. Oh well.

I am having touble sleeping and just wanted to say...

2012-01-16 Thread Bee
FUCK YOU

Re: version()

2012-01-16 Thread Jonathan M Davis
On Monday, January 16, 2012 11:37:13 Marco Leise wrote: I would like to write: void main() { version(!unittest) { run_the_program(); } } This is a case where the trait you check for is so specific that checking for the negation has a clear benefit. I agree with your

Re: version()

2012-01-16 Thread Andrej Mitrovic
One possible workaround: version(Windows) enum Windows = 1; else enum Windows = 0; version(linux) enum Linux = 1; else enum Linux = 0; version(OSX) enum OSX = 1; else enum OSX = 0; version(Posix) enum Posix = 1; else enum Posix = 0;

Re: version()

2012-01-16 Thread Andrej Mitrovic
Although those should be true/false, not 0/1..

Re: I was going to go to sleep

2012-01-16 Thread David
Am 16.01.2012 12:03, schrieb Bee: I really do hate you. Ah I see, a normal D rage

Re: SIMD support...

2012-01-16 Thread Marco Leise
Am 15.01.2012, 11:45 Uhr, schrieb Manu turkey...@gmail.com: On 15 January 2012 08:16, Sean Cavanaugh worksonmymach...@gmail.com wrote: On 1/15/2012 12:09 AM, Walter Bright wrote: On 1/14/2012 9:58 PM, Sean Cavanaugh wrote: MS has three types, __m128, __m128i and __m128d (float, int,

Re: version()

2012-01-16 Thread Peter Alexander
== Quote from Jonathan M Davis (jmdavisp...@gmx.com)'s article On Monday, January 16, 2012 11:37:13 Marco Leise wrote: I would like to write: void main() { version(!unittest) { run_the_program(); } } This is a case where the trait you check for is so specific

Re: Biggest Issue with D - Definition and Versioning

2012-01-16 Thread Peter Alexander
== Quote from Paulo Pinto (pj...@progtools.org)'s article With smaller startups moving to Unity/C#, XNA for XBox 360/Windows/WP7 and Sony now supporting Mono/C# as the main development environment for the VITA and PlaySuite, it might already be too late for D in the gaming world. There are

Re: Biggest Issue with D - Definition and Versioning

2012-01-16 Thread Andrej Mitrovic
I always thought D would be a great language for making tools for gamedevs, e.g. UnrealEd. AFAIK UED was originally written in VBasic before being ported to C++.

Re: Biggest Issue with D - Definition and Versioning

2012-01-16 Thread Paulo Pinto
According to the latest issue from the German games developer magazine, most people only buy one to two AAA games per year. Spending much more money in casual games. As such, what AAA studios use, is to some extent irrelevant. As only a few studios worldwide are able to produce AAA games. For

Re: version()

2012-01-16 Thread Don Clugston
On 16/01/12 01:08, Jonathan M Davis wrote: On Monday, January 16, 2012 01:44:56 Manu wrote: Surely basic logical expressions within a version seem not only logical, but also very necessary? There must be a reason this is impossible, or else I can't believe it's not already like that... People

Re: version()

2012-01-16 Thread Manu
On 16 January 2012 15:30, Don Clugston d...@nospam.com wrote: On 16/01/12 01:08, Jonathan M Davis wrote: On Monday, January 16, 2012 01:44:56 Manu wrote: Surely basic logical expressions within a version seem not only logical, but also very necessary? There must be a reason this is

Re: version()

2012-01-16 Thread Iain Buclaw
On 16 January 2012 14:27, Manu turkey...@gmail.com wrote: On 16 January 2012 15:30, Don Clugston d...@nospam.com wrote: On 16/01/12 01:08, Jonathan M Davis wrote: On Monday, January 16, 2012 01:44:56 Manu wrote: Surely basic logical expressions within a version seem not only logical, but

Re: Biggest Issue with D - Definition and Versioning

2012-01-16 Thread Klaim - Joël Lamotte
Hi, here are my random 2 cents about the gamedev point, as someone who have worked in the game industry and will get to full-indie gamedev in the future : A. C# is used a lot in the industry because : 1. It's easier to code with than C++ and with decent performance; 2. It's hugely easy to

Re: new std.process and Win/DMC runtime issues?

2012-01-16 Thread Steven Schveighoffer
On Mon, 16 Jan 2012 02:49:33 -0500, Nick Sabalausky a@a.a wrote: The limitations of the current std.process are getting to be a big pain in my ass for script-style programs. Last I heard, the new std.process was blocked by issues with the DMC runtime prevent it from working on Windows.

Re: SIMD benchmark

2012-01-16 Thread Andrei Alexandrescu
On 1/15/12 12:56 AM, Walter Bright wrote: I get a 2 to 2.5 speedup with the vector instructions on 64 bit Linux. Anyhow, it's good enough now to play around with. Consider it alpha quality. Expect bugs - but make bug reports, as there's a serious lack of source code to test it with.

Re: start on SIMD documentation

2012-01-16 Thread Andrei Alexandrescu
On 1/13/12 11:02 PM, Walter Bright wrote: On 1/13/2012 8:52 PM, Andrei Alexandrescu wrote: On 1/13/12 10:03 PM, Walter Bright wrote: On 1/13/2012 7:03 PM, Andrei Alexandrescu wrote: How is that possibly different from what you have now? Intrinsic functions are today just a table lookup in

Re: version()

2012-01-16 Thread Manu
On 16 January 2012 17:38, Iain Buclaw ibuc...@ubuntu.com wrote: On 16 January 2012 14:27, Manu turkey...@gmail.com wrote: On 16 January 2012 15:30, Don Clugston d...@nospam.com wrote: On 16/01/12 01:08, Jonathan M Davis wrote: On Monday, January 16, 2012 01:44:56 Manu wrote: Surely

Re: SIMD benchmark

2012-01-16 Thread Manu
On 16 January 2012 18:17, Andrei Alexandrescu seewebsiteforem...@erdani.org wrote: On 1/15/12 12:56 AM, Walter Bright wrote: I get a 2 to 2.5 speedup with the vector instructions on 64 bit Linux. Anyhow, it's good enough now to play around with. Consider it alpha quality. Expect bugs - but

Re: SIMD benchmark

2012-01-16 Thread Andrei Alexandrescu
On 1/16/12 10:46 AM, Manu wrote: A function using float arrays and a function using hardware vectors should certainly not be the same speed. My point was that the version using float arrays should opportunistically use hardware ops whenever possible. Andrei

Re: SIMD benchmark

2012-01-16 Thread Martin Nowak
On Mon, 16 Jan 2012 17:17:44 +0100, Andrei Alexandrescu seewebsiteforem...@erdani.org wrote: On 1/15/12 12:56 AM, Walter Bright wrote: I get a 2 to 2.5 speedup with the vector instructions on 64 bit Linux. Anyhow, it's good enough now to play around with. Consider it alpha quality. Expect

Re: Call site 'ref'

2012-01-16 Thread Timon Gehr
On 01/16/2012 08:31 AM, Alex Rønne Petersen wrote: On 16-01-2012 02:37, Mail Mantis wrote: 2012/1/15 Alex Rønne Petersenxtzgzo...@gmail.com: Hi, I don't know how many times I've made the mistake of passing a local variable to a function which takes a 'ref' parameter. Suddenly, local

Re: version()

2012-01-16 Thread Steven Schveighoffer
On Sun, 15 Jan 2012 19:16:03 -0500, Manu turkey...@gmail.com wrote: On 16 January 2012 02:08, Jonathan M Davis jmdavisp...@gmx.com wrote: On Monday, January 16, 2012 01:44:56 Manu wrote: Surely basic logical expressions within a version seem not only logical, but also very necessary?

Re: SIMD benchmark

2012-01-16 Thread Manu
On 16 January 2012 18:48, Andrei Alexandrescu seewebsiteforem...@erdani.org wrote: On 1/16/12 10:46 AM, Manu wrote: A function using float arrays and a function using hardware vectors should certainly not be the same speed. My point was that the version using float arrays should

Re: SIMD benchmark

2012-01-16 Thread Timon Gehr
On 01/16/2012 05:59 PM, Manu wrote: On 16 January 2012 18:48, Andrei Alexandrescu seewebsiteforem...@erdani.org mailto:seewebsiteforem...@erdani.org wrote: On 1/16/12 10:46 AM, Manu wrote: A function using float arrays and a function using hardware vectors should certainly

Re: SIMD benchmark

2012-01-16 Thread Manu
On 16 January 2012 19:01, Timon Gehr timon.g...@gmx.ch wrote: On 01/16/2012 05:59 PM, Manu wrote: On 16 January 2012 18:48, Andrei Alexandrescu seewebsiteforem...@erdani.org mailto:SeeWebsiteForEmail@**erdani.orgseewebsiteforem...@erdani.org wrote: On 1/16/12 10:46 AM, Manu wrote:

Re: SIMD benchmark

2012-01-16 Thread Michel Fortin
On 2012-01-16 16:59:44 +, Manu turkey...@gmail.com said: On 16 January 2012 18:48, Andrei Alexandrescu seewebsiteforem...@erdani.org wrote: On 1/16/12 10:46 AM, Manu wrote: A function using float arrays and a function using hardware vectors should certainly not be the same speed.

Re: SIMD support...

2012-01-16 Thread suicide
Here is mine: http://suicide.zoadian.de/ext/math/geometry/vector.d i haven't tested (not even compiled) it yet. It needs polishing, but i have not much time to work on it atm. But you may use it as you wish ;) Any suggestions/improvement is welcome. Greetings, Felix Am 16.01.2012, 04:00

Re: SIMD benchmark

2012-01-16 Thread Walter Bright
On 1/16/2012 8:59 AM, Manu wrote: (also the float array is unaligned). Currently, it is 4 byte aligned. But the compiler could align freestanding static arrays on 16 bytes without breaking anything. It just cannot align: struct S { int a; float[4] b; } b on a 16

Re: SIMD benchmark

2012-01-16 Thread Walter Bright
On 1/16/2012 9:21 AM, Manu wrote: x64 can do the swapping too with no penalty, but that is the only architecture that can. Ah, that is a crucial bit of information.

Re: SIMD support...

2012-01-16 Thread Walter Bright
On 1/16/2012 5:06 AM, Marco Leise wrote: I bet there are more programs that could benefit from SSE than is obvious or code that could be rewritten in way, that multiple data sets can be processed simultaneous. I think there's quite a bit more, it's just that using SIMD instructions has

Re: SIMD benchmark

2012-01-16 Thread Iain Buclaw
On 16 January 2012 18:59, Walter Bright newshou...@digitalmars.com wrote: On 1/16/2012 8:48 AM, Andrei Alexandrescu wrote: My point was that the version using float arrays should opportunistically use hardware ops whenever possible. Yes, you're right. The compiler can opportunistically

Re: SIMD support...

2012-01-16 Thread F i L
On Monday, 16 January 2012 at 17:57:38 UTC, suicide wrote: Here is mine: http://suicide.zoadian.de/ext/math/geometry/vector.d i haven't tested (not even compiled) it yet. It needs polishing, but i have not much time to work on it atm. But you may use it as you wish ;) Any

Re: SIMD benchmark

2012-01-16 Thread Walter Bright
On 1/16/2012 11:16 AM, Iain Buclaw wrote: But don't worry, I'm not planning on working on that at the moment :-) Leave that sort of optimisation for the backend to handle please. ;-) Of course. I suspect Intel's compiler does that one, does gcc?

Re: SIMD support...

2012-01-16 Thread F i L
Whoops! opBinary should be opOpAssign in my examples.

Re: SIMD benchmark

2012-01-16 Thread Michel Fortin
On 2012-01-16 17:57:14 +, Andrei Alexandrescu seewebsiteforem...@erdani.org said: On 1/16/12 11:32 AM, Michel Fortin wrote: Andrei's idea could be valid as an optimization when the compiler can see that all the operations can be performed with SIMD ops. In this particular case: if

Limitation with current regex API

2012-01-16 Thread Jerry
Hi all, In general, I'm enjoying the regex respin. However, I ran into one issue that seems to have no clean workaround. Generally, I want to be able to get the start and end indices of matches. With the complete match, this info can be pieced together with match.pre().length and

Re: start on SIMD documentation

2012-01-16 Thread Walter Bright
On 1/16/2012 8:38 AM, Andrei Alexandrescu wrote: Either approach should work perfectly fine; it cheats in style by using an existing language construct that exactly matches the special-cased capability. The current approach cheats badly - it messes with the language's fabric by defining a

Re: start on SIMD documentation

2012-01-16 Thread Andrei Alexandrescu
On 1/16/12 1:32 PM, Walter Bright wrote: On 1/16/2012 8:38 AM, Andrei Alexandrescu wrote: Either approach should work perfectly fine; it cheats in style by using an existing language construct that exactly matches the special-cased capability. The current approach cheats badly - it messes with

Re: SIMD support...

2012-01-16 Thread F i L
On Monday, 16 January 2012 at 19:27:16 UTC, F i L wrote: Whoops! opBinary should be opOpAssign in my examples. wait... no, opBinary was the right one... i'm confusing myself here :D

Re: SIMD benchmark

2012-01-16 Thread Manu
On 16 January 2012 21:27, Michel Fortin michel.for...@michelf.com wrote: In fact, the optimization I'd expect the compiler to do in this case is just wipe out all the code, as it does nothing other than putting a value in a local variable which is never reused later. Yes, my first thought

Re: SIMD benchmark

2012-01-16 Thread Iain Buclaw
On 16 January 2012 19:25, Walter Bright newshou...@digitalmars.com wrote: On 1/16/2012 11:16 AM, Iain Buclaw wrote: But don't worry, I'm not planning on working on that at the moment :-) Leave that sort of optimisation for the backend to handle please. ;-) Of course. I suspect Intel's

Re: version()

2012-01-16 Thread Nick Sabalausky
Don Clugston d...@nospam.com wrote in message news:jf18qg$2vco$1...@digitalmars.com... Make it illegal to reference a version identifier which hasn't been declared. Yes, yes, YES!! Variables have mandatory declarations for a reason: To catch uses of mis-typed variables. Throwing that away

Re: Biggest Issue with D - Definition and Versioning

2012-01-16 Thread Kiith-Sa
A: 1 - I think we're getting close to that point. I do encounter compiler bugs from time to time, but the frequency is rapidly decreasing with the recent releases. We already have the Easier to code and Decent performance parts, but there's a lot of room to improve (standard build system,

Re: new std.process and Win/DMC runtime issues?

2012-01-16 Thread Nick Sabalausky
Steven Schveighoffer schvei...@yahoo.com wrote in message news:op.v76pwcmseav7ka@localhost.localdomain... On Mon, 16 Jan 2012 02:49:33 -0500, Nick Sabalausky a@a.a wrote: The limitations of the current std.process are getting to be a big pain in my ass for script-style programs. Last I

Re: version()

2012-01-16 Thread Adam D. Ruppe
I somewhat rarely use version anymore. I used to use it for different client customizations to my app, but you can't turn features on and off in a a central file like that, since the version= doesn't affect other modules. I switched for a while to static if like this: version(client_a) enum

Re: SIMD support...

2012-01-16 Thread David
Am 16.01.2012 03:54, schrieb JoeCoder: On 1/15/2012 1:42 PM, Walter Bright wrote: A nice vector math library for D that puts us competitive will be a nice addition to Phobos. The gl3n library might be something good to build on: https://bitbucket.org/dav1d/gl3n It looks to be a continuation

Re: version()

2012-01-16 Thread Don
On 16.01.2012 15:27, Manu wrote: On 16 January 2012 15:30, Don Clugston d...@nospam.com mailto:d...@nospam.com wrote: On 16/01/12 01:08, Jonathan M Davis wrote: On Monday, January 16, 2012 01:44:56 Manu wrote: Surely basic logical expressions within a version seem not

Re: version()

2012-01-16 Thread Manu
On 16 January 2012 23:19, Adam D. Ruppe destructiona...@gmail.com wrote: I somewhat rarely use version anymore. I used to use it for different client customizations to my app, but you can't turn features on and off in a a central file like that, since the version= doesn't affect other

Re: SIMD benchmark

2012-01-16 Thread Peter Alexander
On 16/01/12 8:56 PM, Iain Buclaw wrote: On 16 January 2012 19:25, Walter Brightnewshou...@digitalmars.com wrote: On 1/16/2012 11:16 AM, Iain Buclaw wrote: But don't worry, I'm not planning on working on that at the moment :-) Leave that sort of optimisation for the backend to handle

Re: Switching from Ruby to C++ for games

2012-01-16 Thread Nick Sabalausky
Chad J chadjoan@__spam.is.bad__gmail.com wrote in message news:jee6f1$6ra$1...@digitalmars.com... Interesting idea for a challenge: Write an alternative parser for D that uses LOLCODE-like tokens instead of the traditional D tokens. Then you would have a language that has the same

Re: SIMD benchmark

2012-01-16 Thread Manu
On 16 January 2012 23:57, Peter Alexander peter.alexander...@gmail.comwrote: On 16/01/12 8:56 PM, Iain Buclaw wrote: On 16 January 2012 19:25, Walter Brightnewshound2@digitalmars.**comnewshou...@digitalmars.com wrote: On 1/16/2012 11:16 AM, Iain Buclaw wrote: But don't worry, I'm not

Re: SIMD benchmark

2012-01-16 Thread Walter Bright
On 1/16/2012 12:22 PM, Manu wrote: Yes, my first thought when I saw this test was why is it generating any code at all?.. But I tried to forget about that :) I am curious though, what is causing that code (on both sides) to not be eliminated? If I write that in C, I'm sure it would generate

Re: SIMD benchmark

2012-01-16 Thread Walter Bright
On 1/16/2012 1:54 PM, Manu wrote: Unfortunately, if the function was this: void foo(int[] a, int[] b, int[] c) { for (int i=0; i256; i++) a[i] = b[i] + c[i]; } Then it can't vectorize due to aliasing. This is why D needs a __restrict attribute! ;) That's why

Re: SIMD benchmark

2012-01-16 Thread Manu
On 17 January 2012 00:03, Walter Bright newshou...@digitalmars.com wrote: On 1/16/2012 1:54 PM, Manu wrote: Unfortunately, if the function was this: void foo(int[] a, int[] b, int[] c) { for (int i=0; i256; i++) a[i] = b[i] + c[i]; } Then it can't vectorize due

Re: SIMD benchmark

2012-01-16 Thread Simen Kjærås
On Mon, 16 Jan 2012 23:06:12 +0100, Manu turkey...@gmail.com wrote: On 17 January 2012 00:03, Walter Bright newshou...@digitalmars.com wrote: On 1/16/2012 1:54 PM, Manu wrote: Unfortunately, if the function was this: void foo(int[] a, int[] b, int[] c) { for (int i=0; i256;

Re: SIMD support...

2012-01-16 Thread Simen Kjærås
On Mon, 16 Jan 2012 22:26:55 +0100, David d...@dav1d.de wrote: Am 16.01.2012 03:54, schrieb JoeCoder: On 1/15/2012 1:42 PM, Walter Bright wrote: A nice vector math library for D that puts us competitive will be a nice addition to Phobos. The gl3n library might be something good to build

Re: SIMD benchmark

2012-01-16 Thread Simen Kjærås
On Mon, 16 Jan 2012 23:22:21 +0100, Simen Kjærås simen.kja...@gmail.com wrote: On Mon, 16 Jan 2012 23:06:12 +0100, Manu turkey...@gmail.com wrote: On 17 January 2012 00:03, Walter Bright newshou...@digitalmars.com wrote: On 1/16/2012 1:54 PM, Manu wrote: Unfortunately, if the

Re: SIMD support...

2012-01-16 Thread JoeCoder
On 1/16/2012 4:26 PM, David wrote: Why does phobos, the std. lib, need a vector-lib? I haven't seen any other language with something like gl3n in the std. I guess this depends on the goals for phobos. Is it minimal, or batteries included? As for not seeing it in other languages, I don't

Re: SIMD benchmark

2012-01-16 Thread Iain Buclaw
On 16 January 2012 21:57, Peter Alexander peter.alexander...@gmail.com wrote: On 16/01/12 8:56 PM, Iain Buclaw wrote: On 16 January 2012 19:25, Walter Brightnewshou...@digitalmars.com  wrote: On 1/16/2012 11:16 AM, Iain Buclaw wrote: But don't worry, I'm not planning on working on that at

Re: SIMD support...

2012-01-16 Thread Iain Buclaw
On 16 January 2012 22:32, JoeCoder dnewsgro...@yage3d.net wrote: On 1/16/2012 4:26 PM, David wrote: Why does phobos, the std. lib, need a vector-lib? I haven't seen any other language with something like gl3n in the std. I guess this depends on the goals for phobos.  Is it minimal, or

Re: SIMD benchmark

2012-01-16 Thread Walter Bright
On 1/16/2012 2:06 PM, Manu wrote: Surely it would be possible for them to be overlapping slices? Not allowed, treated like array bounds checking.

Re: Biggest Issue with D - Definition and Versioning

2012-01-16 Thread Walter Bright
On 1/16/2012 1:02 PM, Kiith-Sa wrote: Also, some of the indie PC developers might be more likely to try out D than the AAA industry - if we get some decent basic libraries. Keep in mind that D can directly access any C library. The Deimos project https://github.com/D-Programming-Deimos/ is

byKey and byValue

2012-01-16 Thread Andrei Alexandrescu
I just submitted a pull request for true byKey and byValue ranges. https://github.com/andralex/druntime/commit/cd7b477b83cc8a75a90258bd2ab63fa8c92ba10b Over time I plan to slowly but surely migrate stuff from the opaque implementation in druntime/src/rt/aaA.d into the templated implementation

Re: Biggest Issue with D - Definition and Versioning

2012-01-16 Thread Kiith-Sa
Walter Bright wrote: On 1/16/2012 1:02 PM, Kiith-Sa wrote: Also, some of the indie PC developers might be more likely to try out D than the AAA industry - if we get some decent basic libraries. Keep in mind that D can directly access any C library. The Deimos project

Replacing version( Win32 ) with version( Windows )

2012-01-16 Thread Daniel Green
I'm running across version( Win32 ) in phobos. Often the code is perfectly valid for Win64 as well. Is it acceptable to replace version( Win32 ) with version( Windows )?

Re: Biggest Issue with D - Definition and Versioning

2012-01-16 Thread Walter Bright
On 1/16/2012 3:26 PM, Kiith-Sa wrote: I'm well aware of the fact - my work depends on SDL, OpenGL and FreeType using the Derelict bindings (Those probably don't belong to Deimos as they're not absolutely thin bindings although they don't wrap the APIs in any way) It would be nice to split the

  1   2   >