SIMD in LDC is currently broken
What problems did you have with it? It seems to work fine for me.
And is there also a pragma omp critical analogon?
On Tuesday, 2 October 2012 at 20:16:36 UTC, Peter Alexander wrote:
On Tuesday, 2 October 2012 at 19:15:19 UTC, Farmer wrote:
Hi,
I am tempted to start D programming but for me it is crucrial
to be able to parallelize for-loops as can be done
On Tuesday, 2 October 2012 at 21:06:04 UTC, Manu wrote:
I just installed dmd 2.60 in linux, and it seems std.intrinsic
isn't
there... is this my fault somehow, or has it been removed?
I need the bsr() intrinsic which (used to?) live there.
import core.bitop;
On 3 October 2012 00:17, Iain Buclaw ibuc...@ubuntu.com wrote:
On Tuesday, 2 October 2012 at 21:06:04 UTC, Manu wrote:
I just installed dmd 2.60 in linux, and it seems std.intrinsic isn't
there... is this my fault somehow, or has it been removed?
I need the bsr() intrinsic which (used to?)
On 10/2/12, Walter Bright newshou...@digitalmars.com wrote:
On 9/30/2012 11:31 AM, deadalnix wrote:
If you know that a string is 0 terminated, you can easily create a slice
from it as follow :
char* myZeroTerminatedString;
char[] myZeroTerminatedString[0 .. strlen(myZeroTerminatedString)];
On Tuesday, 2 October 2012 at 21:13:33 UTC, Farmer wrote:
And is there also a pragma omp critical analogon?
For critical sections you could use a low-level mutex. I don't do
much parallel stuff in D, so I don't know if this is the
preferred way, but it's an option.
On Monday, 1 October 2012 at 17:31:11 UTC, Habibutsu wrote:
Anybody knows, project qtd
(http://www.dsource.org/projects/qtd/) is alive or died? Last
changes was one year ago. Tracking system contains critical
bugs and nobody fixes. There may be other working bindings for
Qt?
Hey, yes I
On Tue, 02 Oct 2012 19:23:48 +0200
Jonathan M Davis jmdavisp...@gmx.com wrote:
On Tuesday, October 02, 2012 19:10:53 monarch_dodra wrote:
Ideally, only size_t would be allowed. Reality makes it so that we
need ulong in some cases (e.g. iota). Given that fact, you'd ideally
restrict it to
Some pull requests are rather trivial to approve and merge (e.g. small
doc fixes, typo fixes), and it would be nice if a pull requester could
tag a pull as trivial when the pull is made.
Otherwise I guess we could start using a convention and add [trivial]
before the title? I think it might help
On Tuesday, 2 October 2012 at 21:30:35 UTC, Andrej Mitrovic wrote:
On 10/2/12, Walter Bright newshou...@digitalmars.com wrote:
On 9/30/2012 11:31 AM, deadalnix wrote:
If you know that a string is 0 terminated, you can easily
create a slice
from it as follow :
char* myZeroTerminatedString;
On Monday, 1 October 2012 at 16:25:12 UTC, Andrei Alexandrescu
wrote:
The project is not live, it will be within a few days. In the
spirit of having the community actively participate, I'm making
this as transparent as it gets. Please comment:
On Tuesday, 2 October 2012 at 21:03:36 UTC, jerro wrote:
SIMD in LDC is currently broken
What problems did you have with it? It seems to work fine for
me.
Can you post an example of doing a simple arithmetic with two
'float4's? My simple tests either fail with LLVM errors or don't
produce
Also, I'm using the LDC off the official Arch community repo.
I'm starting to contribute to DMD by fixing some bugs, but I need to
run the test-suite. Anyone know how this is done on win32? There's a
makefile in the test dir but what I don't know is if I need to set up
my directory structure in any special way?
Is it simpler to just make the pull request
On 10/3/12, Jakob Ovrum jakobov...@gmail.com wrote:
writefln cannot be @safe if it has to support an unsafe format
specifier. It's hidden because it affects every call to
writefln, even if it doesn't use the unsafe format specifier.
Ah damn I completely forgot about @safe. I tend to avoid
On Wed, Oct 03, 2012 at 03:07:14AM +0200, Andrej Mitrovic wrote:
On 10/3/12, Jakob Ovrum jakobov...@gmail.com wrote:
writefln cannot be @safe if it has to support an unsafe format
specifier. It's hidden because it affects every call to writefln,
even if it doesn't use the unsafe format
import core.simd, std.stdio;
void main()
{
float4 a = 1, b = 2;
writeln((a + b).array); // WORKS: [3, 3, 3, 3]
float4 c = [1, 2, 3, 4]; // ERROR: Stored value type does
// not match pointer operand type!
// [..a bunch of LLVM error
On 10/3/12, Andrej Mitrovic andrej.mitrov...@gmail.com wrote:
I'm starting to contribute to DMD by fixing some bugs, but I need to
run the test-suite. Anyone know how this is done on win32? There's a
makefile in the test dir but what I don't know is if I need to set up
my directory structure
On 10/3/12, Andrej Mitrovic andrej.mitrov...@gmail.com wrote:
Hmm I was trying to find the autotester source script to figure this
out on my own, but I can't find the source anywhere. :) I'm pretty
sure I saw it on github somewhere though?
Ok found it: https://github.com/braddr/d-tester
On 10/3/12, Andrej Mitrovic andrej.mitrov...@gmail.com wrote:
Ok found it: https://github.com/braddr/d-tester
Yikes, this is cygwin. Well if nothing else I'll make a D driver
script, I'm not in the mood to deal with cygwin or virtual machines.
On 10/2/12 8:23 PM, MattCoder wrote:
On Monday, 1 October 2012 at 16:25:12 UTC, Andrei Alexandrescu wrote:
The project is not live, it will be within a few days. In the spirit
of having the community actively participate, I'm making this as
transparent as it gets. Please comment:
On Tuesday, October 02, 2012 18:21:30 H. S. Teoh wrote:
On Wed, Oct 03, 2012 at 03:07:14AM +0200, Andrej Mitrovic wrote:
On 10/3/12, Jakob Ovrum jakobov...@gmail.com wrote:
writefln cannot be @safe if it has to support an unsafe format
specifier. It's hidden because it affects every call
On Tuesday, 2 October 2012 at 23:21:13 UTC, Andrej Mitrovic wrote:
Some pull requests are rather trivial to approve and merge
(e.g. small
doc fixes, typo fixes), and it would be nice if a pull
requester could
tag a pull as trivial when the pull is made.
Otherwise I guess we could start using
jerro wrote:
This code gives me internal compiler errors with GDC and DMD
too (with float4 c = [1, 2, 3, 4] commented out). I'm using
DMD 2.060 and a recent versions of GDC and LDC on 64 bit Linux.
Yes the SIMD situation isn't entirely usable right now with DMD
and LDC. Only simple vector
On 10/01/2012 09:39 PM, Bernard Helyer wrote:
Our results from 14 Java applications
Only 14? So it's a useless statistic.
No, that isn't true. How many language decisions in D are based on an
analysis of even 5 programs, let alone 14? What if you were testing to
see how fair a coin was,
On Tue, Oct 02, 2012 at 07:50:09PM -0700, Jonathan M Davis wrote:
On Tuesday, October 02, 2012 18:21:30 H. S. Teoh wrote:
On Wed, Oct 03, 2012 at 03:07:14AM +0200, Andrej Mitrovic wrote:
On 10/3/12, Jakob Ovrum jakobov...@gmail.com wrote:
writefln cannot be @safe if it has to support an
On Wednesday, 3 October 2012 at 05:04:01 UTC, H. S. Teoh wrote:
Yes that's what I mean. If the format string is known at
compile-time
and known to involve only @safe code, then this would work.
Something
like this might work if CTFE is used to parse the format string
piecemeal (i.e., translate
I'm trying to debug the Mac OS X port of DWT. Almost as soon as a DWT
application starts to process events I receive a segmentation fault. The
error happens in the objc_msgSend C function when calling an
Objective-C method. GDB backtrace:
http://pastebin.com/0fmUmPQ1
The source code of DWT
I haven't tried to use DMD 2.060 yet, will see if i've got time
later.
On 10/2/12, Jesse Phillips jessekphillip...@gmail.com wrote:
I've made the changes needed to get past the linker error
I'm sorry, I was completely wrong about STDAPI being extern(C). I saw
EXTERN_C and immediately thought this was the calling convention, it's
not:
#define STDAPI
On 10/2/12, Jesse Phillips jessekphillip...@gmail.com wrote:
Thank you, making these changes did do the trick
As mentioned in the other thread I was wrong, it's extern(Windows),
but implib produced an import lib which didn't quite work. coffimplib
does the trick though.
On Tuesday, 2 October 2012 at 09:48:00 UTC, Andrej Mitrovic wrote:
I'm sorry, I was completely wrong about STDAPI being extern(C).
I saw
EXTERN_C and immediately thought this was the calling
convention, it's
not:
#define STDAPI EXTERN_C HRESULT STDAPICALLTYPE
#define
Without optimization the range and algorithm method takes about
10 times as long as the simple code below it, with no array
bounds checking and optimization it takes six times as long. Why
is the difference so huge? I'd expect a moderate overhead but
that's a big difference.
module main;
On Tuesday, 2 October 2012 at 20:48:31 UTC, ixid wrote:
Without optimization the range and algorithm method takes about
10 times as long as the simple code below it, with no array
bounds checking and optimization it takes six times as long.
Why is the difference so huge? I'd expect a moderate
On 10/02/2012 10:48 PM, ixid wrote:
Without optimization the range and algorithm method takes about 10 times
as long as the simple code below it, with no array bounds checking and
optimization it takes six times as long. Why is the difference so huge?
I'd expect a moderate overhead but that's a
On 10/03/2012 12:11 AM, Timon Gehr wrote:
...
$ cat ixidbench.d
module main;
import std.stdio, std.algorithm, std.range, std.datetime;
enum MAX = 10_000_000_000UL;
void main() {
StopWatch sw;
sw.start;
auto sum1 = MAX.iota.map!(x = x * x).reduce!a + b;
sw.stop;
On Tuesday, 2 October 2012 at 22:13:10 UTC, Timon Gehr wrote:
On 10/03/2012 12:11 AM, Timon Gehr wrote:
...
$ cat ixidbench.d
module main;
import std.stdio, std.algorithm, std.range, std.datetime;
enum MAX = 10_000_000_000UL;
void main() {
StopWatch sw;
sw.start;
auto sum1 =
Do you know if here the problem is in Phobos or if I'm asking
Phobos to do something too much hard?
import std.algorithm: map, reduce;
import std.range: zip;
struct S {}
alias bool function(S) F;
F foo(T)(T) {
return p = true;
}
F bar(F r1, F r2) {
return p = true;
}
F spam(S[] ps) {
How do I call std_stdio_static_this() in std.stdio from a
dynamically loaded shared library (osx) ?
I need to do this in my scenario:
1) main program is launched
2) dynamic library is created
3) dynamic library is loaded and a function from it is called
4) everything works fine until a
On Tuesday, 2 October 2012 at 22:13:10 UTC, Timon Gehr wrote:
On 10/03/2012 12:11 AM, Timon Gehr wrote:
...
$ cat ixidbench.d
module main;
import std.stdio, std.algorithm, std.range, std.datetime;
enum MAX = 10_000_000_000UL;
void main() {
StopWatch sw;
sw.start;
auto sum1 =
On Wednesday, 3 October 2012 at 01:21:38 UTC, ixid wrote:
If it were (range, seed) then there would be no problem:
[1,1,1].reduce!a + b + 2(0).writeln; // == 9
My thoughts exactly.
While fiddling with this I came across something that seems odd
in the behaviour of reduce and wondered if it's intended. It
rather limits the usefulness of reduce with UFCS to a + b and
a - b.
Reduce works correctly when provided with a seed argument:
reduce!a + b + 2(0, [1,1,1]).writeln;
A typical use case is to find the maximum of a range (there is
an example of this in the documentation at
http://dlang.org/phobos/std_algorithm.html#reduce). If you don't
know the highest possible value of elements, then you couldn't
come up with an appropriate seed for this case.
Fixing
http://d.puremagic.com/issues/show_bug.cgi?id=8741
Don clugd...@yahoo.com.au changed:
What|Removed |Added
Keywords||wrong-code
http://d.puremagic.com/issues/show_bug.cgi?id=8741
Don clugd...@yahoo.com.au changed:
What|Removed |Added
Keywords||pull
--- Comment #2 from
http://d.puremagic.com/issues/show_bug.cgi?id=8745
Don clugd...@yahoo.com.au changed:
What|Removed |Added
CC||clugd...@yahoo.com.au
---
http://d.puremagic.com/issues/show_bug.cgi?id=8745
--- Comment #2 from monarchdo...@gmail.com 2012-10-02 01:19:17 PDT ---
(In reply to comment #1)
The idea that for floating point, 'is' and '==' should be the same, is wrong.
See bug 3632 for further discussion. I suspect this is a duplicate
http://d.puremagic.com/issues/show_bug.cgi?id=8743
--- Comment #5 from Andrej Mitrovic andrej.mitrov...@gmail.com 2012-10-02
02:25:42 PDT ---
(In reply to comment #4)
void rehash() { memo = null; }
Maybe do you mean something like this?
void rehash() { memo.rehash; }
void clear() {
http://d.puremagic.com/issues/show_bug.cgi?id=8743
--- Comment #6 from bearophile_h...@eml.cc 2012-10-02 02:54:21 PDT ---
(In reply to comment #5)
enum bool isClassStruct = (is(fun == class) || is(fun == struct));
No need for extra parentheses:
enum bool isClassStruct = is(fun == class)
http://d.puremagic.com/issues/show_bug.cgi?id=8746
Summary: rehash AA property doesn't work with constant Tuple
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: P2
http://d.puremagic.com/issues/show_bug.cgi?id=8743
--- Comment #8 from Andrej Mitrovic andrej.mitrov...@gmail.com 2012-10-02
03:08:44 PDT ---
(In reply to comment #6)
This mixin template is useful. A disadvantage is that it doesn't follow the
API
(usage) of the Phobos memoize. So maybe it
http://d.puremagic.com/issues/show_bug.cgi?id=8743
--- Comment #7 from Andrej Mitrovic andrej.mitrov...@gmail.com 2012-10-02
03:05:48 PDT ---
(In reply to comment #6)
If the arguments are constant it doesn't work:
int slowFunc(in int a, in int b)
Seems to be a new bug related to Tuple:
http://d.puremagic.com/issues/show_bug.cgi?id=8743
--- Comment #9 from Andrej Mitrovic andrej.mitrov...@gmail.com 2012-10-02
03:12:47 PDT ---
(In reply to comment #8)
(In reply to comment #6)
This mixin template is useful. A disadvantage is that it doesn't follow the
API
(usage) of the
http://d.puremagic.com/issues/show_bug.cgi?id=8743
--- Comment #10 from Andrej Mitrovic andrej.mitrov...@gmail.com 2012-10-02
03:17:42 PDT ---
(In reply to comment #9)
(In reply to comment #8)
(In reply to comment #6)
This mixin template is useful. A disadvantage is that it doesn't
http://d.puremagic.com/issues/show_bug.cgi?id=8575
Kenji Hara k.hara...@gmail.com changed:
What|Removed |Added
Keywords||pull, rejects-valid
http://d.puremagic.com/issues/show_bug.cgi?id=8745
Rainer Schuetze r.sagita...@gmx.de changed:
What|Removed |Added
CC||r.sagita...@gmx.de
http://d.puremagic.com/issues/show_bug.cgi?id=8655
--- Comment #1 from Andrej Mitrovic andrej.mitrov...@gmail.com 2012-10-02
16:04:02 PDT ---
(In reply to comment #0)
import std.typecons;
import std.bitmanip;
static import core.stdc.config;
alias Typedef!(core.stdc.config.c_ulong)
http://d.puremagic.com/issues/show_bug.cgi?id=8544
--- Comment #1 from Andrej Mitrovic andrej.mitrov...@gmail.com 2012-10-02
16:53:34 PDT ---
I'd like to fix this myself. But I'm not sure how this should be exposed in the
Runtime struct. Should it be two properties, 'argc' and 'argv', or a
http://d.puremagic.com/issues/show_bug.cgi?id=8544
--- Comment #2 from Andrej Mitrovic andrej.mitrov...@gmail.com 2012-10-02
16:54:34 PDT ---
(In reply to comment #1)
I'd like to fix this myself. But I'm not sure how this should be exposed in
the
Runtime struct. Should it be two
http://d.puremagic.com/issues/show_bug.cgi?id=8544
Alex R�nne Petersen a...@lycus.org changed:
What|Removed |Added
CC||a...@lycus.org
101 - 160 of 160 matches
Mail list logo