On Friday, 3 November 2023 at 15:32:08 UTC, Sergey wrote:
On Friday, 3 November 2023 at 15:11:31 UTC, Bogdan wrote:
Hi everyone,
I was playing around with the intel-intrinsics library, trying
to improve the speed of a simple area function. I could not
see any performance improvements from
Hi everyone,
I was playing around with the intel-intrinsics library, trying to
improve the speed of a simple area function. I could not see any
performance improvements from the non-SIMD implementation. The
SIMD version is a little bit slower even with LDC2 and --o3. Can
anyone help me to
Hi everyone,
I am trying to build dub in a docker container on a Mac M1 and
unfortunately all processes started with the `execute` function
from `std.process` always fails with -11. Because of this the
`build.d` or `dub` are unusable on this environment.
The container that I am using is
Hi,
I tried to update my server from dmd v2.096.1 to v2.097 and I
started getting this linker error:
```
Linking...
/usr/bin/ld:
.dub/build/executable-ssl11-debug-linux.posix-x86_64-dmd_v2.097.2-beta.1-7651E13F70724FF6B1F8D8B61B1AEABD/gis-collective-api.o: in function
On Friday, 5 March 2021 at 14:42:07 UTC, Petar Kirov [ZombineDev]
wrote:
On Friday, 5 March 2021 at 08:23:09 UTC, Bogdan wrote:
[...]
I suggest this:
enum globalConfig = 32;
int globalValue = 22;
immutable globaImmutablelValue = 22;
enum isManifestConstant(alias symbol) =
I was using a trick with dmd to check for manifest constants
which worked until dmd v2.094. Yesterday I tried it on the latest
compiler and it failed with:
source/introspection/manifestConstant.d(37,28): Error: need this
for name of type string
source/introspection/type.d(156,13): Error:
Hi,
I remember that I saw a while ago some PRs related to adding a
git url for a dependency in the dub's package.json. I looked
today in the docs and I can't find any info about this. What is
the progress for this feature? Can we use it already?
On Sunday, 6 October 2019 at 11:53:29 UTC, NaN wrote:
You should probably have a look at this...
https://github.com/AuburnSounds/intel-intrinsics
Thanks, that looks quite useful.
Also, it seems that I need to use either LDC or GDC instead of
DMD. :)
On Saturday, 21 September 2019 at 14:31:15 UTC, Stefan Koch wrote:
On Saturday, 21 September 2019 at 13:42:09 UTC, Bogdan wrote:
Well, this seems to be working:
float[4] doSimd(float[4] values, float delta)
{
float4 v_delta = delta;
float4 v_values = __simd(XMM.ADDPS,
Well, this seems to be working:
float[4] doSimd(float[4] values, float delta)
{
float4 v_delta = delta;
float4 v_values = __simd(XMM.ADDPS,
__simd(XMM.LODAPS, values[0]),
v_delta);
return [v_values[0],
Here's a cleaned up version:
```
import std.stdio;
import core.simd;
void main()
{
float[4] values = [1.0f, 2.0f, 3.0f, 4.0f];
float delta = 15.0f;
writeln(doSimd(values, delta));
}
float[4] doSimd(float[4] values, float delta)
{
float4 v_delta = delta;
float4 v_values = values;
I'm trying to understand how to use the `core.simd`
functionality, and I'm having trouble initializing a float4
vector.
Here's my example code:
```
import std.stdio;
import core.simd;
void main()
{
float[4] values = [1.0f, 2.0f, 3.0f, 4.0f];
float delta = 15.0f;
writeln(doSimd(values,
On Wednesday, 15 May 2019 at 13:19:36 UTC, drug wrote:
You can use predicate for this purpose:
```
auto rbt = redBlackTree!((a, b) => a.ID < b.ID, KeyController);
```
https://run.dlang.io/is/CNRTQf
Even better, thank you!
On Wednesday, 15 May 2019 at 13:15:50 UTC, Stefan Koch wrote:
Key controller cannot be compared by less
which is why it fails, give it an opCmp and it'll work.
Works fine, thank you! For some reason, I thought that this
template uses references:
```
enum KeyID: uint
{
KEY_A,
I don't have any experience with using templates. Is it possible
to create a RB tree containing structs, where the nodes are
ordered by one struct member?
```
import std.stdio;
import std.container;
enum KeyID: uint
{
KEY_A,
KEY_S,
KEY_D,
KEY_W
}
struct
On Sunday, 12 May 2019 at 17:53:56 UTC, Bastiaan Veelo wrote:
If I understand your question correctly, you have two enums of
equal length, and you want to convert members across enums
according to their position, right?
My question was very vague, sorry about that.
In my use case I'd like to
What would be the most straight-forward way of mapping the
members of an enum to the members of another enum (one-to-one
mapping) at compile time?
On Saturday, 10 March 2018 at 18:49:48 UTC, Jonathan M Davis
wrote:
Check out
https://dlang.org/phobos/std_bitmanip.html#peek
https://dlang.org/phobos/std_bitmanip.html#read
They can be used to read integral values from a range of
ubytes. You can use either std.file.read or std.stdio.File
... I accidentally posted that before it was complete because I
kept pressing TAB in order to indent ...
Anyway, I'd like to know if there exists such a thing as
```
int a = stream.ReadInt32();
```
I'm working on a pet project which involves reading various
structure types, or just multi-byte values (uin32_t, uint16_t,
etc) from files, or just from ubyte arrays.
Here's how I've been dealing with some of these situations so far:
```
/// Helper structure used to read each of the file
I'd like to distinguish between regular text and code, maybe have
quotes, etc.
On Monday, 18 December 2017 at 22:49:30 UTC, unleashy wrote:
On Friday, 15 December 2017 at 21:56:48 UTC, Steven
Schveighoffer wrote:
On 12/15/17 10:08 AM, Kagamin wrote:
Maybe this https://issues.dlang.org/show_bug.cgi?id=18084
Thanks for looking into this. I created a PR to fix.
Szabo,
On Saturday, 16 December 2017 at 12:01:49 UTC, Steven
Schveighoffer wrote:
On 12/16/17 5:12 AM, bauss wrote:
On Saturday, 16 December 2017 at 08:07:30 UTC, Szabo Bogdan
wrote:
On Friday, 15 December 2017 at 21:56:48 UTC, Steven
Schveighoffer wrote:
On 12/15/17 10:08 AM, Kagamin wrote:
Maybe
On Friday, 15 December 2017 at 13:56:41 UTC, Kagamin wrote:
You said tests fail?
class SourceResult
{
private const
{
string file;
size_t line;
}
this(string fileName = __FILE__, size_t line = __LINE__,
size_t range = 6) nothrow
On Friday, 15 December 2017 at 21:56:48 UTC, Steven Schveighoffer
wrote:
On 12/15/17 10:08 AM, Kagamin wrote:
Maybe this https://issues.dlang.org/show_bug.cgi?id=18084
Thanks for looking into this. I created a PR to fix.
Szabo, can you please try with this patch and see if it fixes
your
On Friday, 15 December 2017 at 09:24:07 UTC, Kagamin wrote:
Try printf debugging in case argument is invalid.
ah .. ok ...
I tried to debug the issue and it looks like the filename is
valid and there is no null value.
I am thinking that the value is destroyed before it reach the
On Thursday, 14 December 2017 at 14:47:25 UTC, Kagamin wrote:
writeln(fileName);
if (!fileName.exists)
{
return;
}
:)
I'm not sure I understand this solution...
Hi,
I noticed that sometimes on windows this line of code crashes the
test suites.
https://github.com/gedaiu/fluent-asserts/blob/master/core/fluentasserts/core/results.d#L1072
This exception can be captured only with a debugger... is it a
dmd bug?
```
Thread 25CC created, Entry:
Hi,
I am wondering if there is any way of getting the code coverage
at runtime... As a I seen in the runtime, the .lst files are
created inside this module dealocator:
https://github.com/dlang/druntime/blob/master/src/rt/cover.d#L152
and the `Cover[] gdata;` is private, so no way of
On Saturday, 6 May 2017 at 15:01:16 UTC, Adam D. Ruppe wrote:
On Saturday, 6 May 2017 at 14:14:41 UTC, Szabo Bogdan wrote:
oh yes, I get it... begin and end are `SysTime`.. there is any
workaround for this?
Don't use pure?
I don't think any of the SysTime conversion methods are pure
since
On Saturday, 6 May 2017 at 13:21:10 UTC, Adam D. Ruppe wrote:
On Saturday, 6 May 2017 at 13:19:17 UTC, Szabo Bogdan wrote:
a.begin.toISOExtString,
I believe that function is not marked pure if it is a SysTime
because it needs to pull global timezone info.
What is the type of a.begin?
oh
Hi,
I'm trying to write a function that saves some structs as csv
file:
```
string toCsv(const(StatStorage) storage) {
return storage.values
.map!(a => [ a.name, a.begin.toISOExtString,
a.end.toISOExtString, a.status.to!string ])
.map!(a => a.join(','))
.join('\n');
}
```
I
On Sunday, 30 April 2017 at 20:31:09 UTC, Szabo Bogdan wrote:
Hi,
I noticed that on different platforms the
`object.Throwable.TraceInfo` has different formats. A program
compiled on osx with ldc2 has all the TraceInfo empty... Why?
I want to parse those strings or somehow iterate trough all
Hi,
I noticed that on different platforms the
`object.Throwable.TraceInfo` has different formats. A program
compiled on osx with ldc2 has all the TraceInfo empty... Why?
I want to parse those strings or somehow iterate trough all the
stack elements, but if I get a different format on
On Sunday, 5 July 2015 at 09:46:19 UTC, ketmar wrote:
On Sun, 05 Jul 2015 21:39:23 +1200, Rikki Cattermole wrote:
Of course of course.
Valid options in failing gracefully include resetting the data
and
informing the user. Also giving them an option to send a bug
report to
the devs.
Point
Hi,
Recently while I was reviewing some swift code, a colleague left
me the impression that I am the one with the bad habits and these
were learned while coding in D. I still think that I proposed
some changes to avoid some bugs but I was told that I am focusing
on defensive programming and
Hi,
How I can sign a request for flickrl oauth api?
https://www.flickr.com/services/api/auth.oauth.html#request_token
there is no HMAC-SHA1 algorithm in phobos library... should I
implement it from scratch?
Thanks,
Bogdan
which lib do you recommand?
On Thursday, 25 September 2014 at 16:19:41 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Thu, Sep 25, 2014 at 03:57:36PM +, szabo bogdan via
Digitalmars-d-learn wrote:
Hi,
How I can sign a request for flickrl oauth api?
https://www.flickr.com/services/api
On Thursday, 25 September 2014 at 17:09:40 UTC, Adam D. Ruppe
wrote:
On Thursday, 25 September 2014 at 17:03:43 UTC, John Chapman
wrote:
http://dlang.org/phobos/std_digest_sha.html#SHA1
Not quite the same, the oauth requires hmac.
When I did this in my oauth.d for twitter and stuff, I used
39 matches
Mail list logo