00:34:05 | * | darkf_ joined #nimrod |
00:36:21 | * | darkf quit (Ping timeout: 240 seconds) |
00:39:16 | * | darkf_ is now known as darkf |
01:27:23 | * | q66 quit (Quit: Leaving) |
01:32:22 | * | willwillson quit (Ping timeout: 260 seconds) |
01:38:13 | * | darkf_ joined #nimrod |
01:39:33 | * | darkf quit (Ping timeout: 240 seconds) |
01:42:27 | * | saml_ joined #nimrod |
01:43:08 | * | darkf_ quit (Ping timeout: 272 seconds) |
01:43:13 | * | mwbrown joined #nimrod |
01:46:36 | * | BlameStross joined #nimrod |
01:48:38 | * | saml_ quit (Ping timeout: 272 seconds) |
01:49:26 | * | saml_ joined #nimrod |
01:53:10 | * | OrionPK quit (Read error: Connection reset by peer) |
02:28:05 | * | Varriount joined #nimrod |
02:28:42 | Varriount | Araq, dom96: Ok, the repository for the file event monitoring module is up at github.com/Varriount/Filemon |
02:29:26 | Varriount | The repository contains a patch file with the changes required to make the filemon module work with the nimrod source tree. |
02:30:26 | * | darkf joined #nimrod |
02:47:22 | * | darkf_ joined #nimrod |
02:48:45 | * | darkf quit (Ping timeout: 240 seconds) |
02:49:26 | * | darkf_ is now known as darkf |
03:00:40 | * | Varriount_ joined #nimrod |
03:00:45 | * | darkf quit (Ping timeout: 240 seconds) |
03:01:11 | * | darkf joined #nimrod |
03:03:45 | * | Varriount quit (Ping timeout: 246 seconds) |
03:09:14 | * | OrionPK joined #nimrod |
03:35:11 | NimBot | Varriount/NimLime master 31df13b Erik O'Leary [+1 ±2 -0]: Fixed issue highlighting on procs |
03:39:32 | * | mwbrown quit (Ping timeout: 260 seconds) |
03:50:10 | * | kshlm joined #nimrod |
04:06:57 | * | saml_ quit (Ping timeout: 245 seconds) |
04:23:52 | * | flaviu quit (Ping timeout: 260 seconds) |
04:25:08 | * | darkf quit (Ping timeout: 250 seconds) |
04:26:56 | * | darkf joined #nimrod |
04:47:20 | * | ARCADIVS joined #nimrod |
05:30:56 | * | kshlm quit (Quit: Konversation terminated!) |
05:41:17 | * | gkoller joined #nimrod |
05:44:15 | * | Demos quit (Read error: Connection reset by peer) |
06:18:57 | * | filwit quit (Quit: Leaving) |
06:19:43 | * | gsingh93 quit (Quit: Connection closed for inactivity) |
07:06:27 | * | bogen quit (Quit: Leaving.) |
07:09:18 | * | kunev joined #nimrod |
07:51:33 | * | Araq quit (Ping timeout: 240 seconds) |
07:52:04 | * | Amrykid quit (Ping timeout: 240 seconds) |
07:52:34 | * | dom96 quit (Ping timeout: 240 seconds) |
07:53:12 | * | Araq_bnc joined #nimrod |
07:54:11 | * | Amrykid joined #nimrod |
07:55:34 | * | Araq_bnc is now known as Araq |
07:57:11 | * | dom96 joined #nimrod |
08:06:51 | * | ARCADIVS quit (Quit: WeeChat 0.4.3) |
08:29:19 | * | Matthias247 joined #nimrod |
09:12:08 | Skrylar | o_O |
09:13:25 | * | Trixar_za joined #nimrod |
09:27:38 | * | darkf_ joined #nimrod |
09:29:18 | * | darkf quit (Ping timeout: 260 seconds) |
09:35:06 | * | noam quit (Quit: Leaving) |
09:35:45 | * | darkf_ is now known as darkf |
10:02:22 | * | Boscop_ quit (Read error: Connection reset by peer) |
10:02:47 | * | Boscop_ joined #nimrod |
10:03:24 | * | zahary quit (Quit: Leaving.) |
10:08:04 | * | kunev quit (Ping timeout: 255 seconds) |
10:08:49 | * | kunev joined #nimrod |
10:12:33 | * | [CBR]Unspoken joined #nimrod |
10:59:14 | * | Fr4n quit (Ping timeout: 255 seconds) |
11:06:01 | * | ome joined #nimrod |
11:16:03 | * | will joined #nimrod |
11:20:28 | * | kokozedman joined #nimrod |
11:21:10 | kokozedman | hello everyone, I'm new here and also am new with Nimrod; I'm really interested in this finding and have some questions |
11:21:58 | kokozedman | I'd like to try this to build applications for embedded routers (MIPS32 architecture), has there been any past success in that area? |
11:24:12 | * | Boscop__ joined #nimrod |
11:27:03 | * | Boscop_ quit (Ping timeout: 240 seconds) |
11:28:31 | * | io2 joined #nimrod |
11:52:45 | kokozedman | looks like a success, I tried to compile the example the in JSON module and it worked ... I just hard to use --cpu:i386 to disable an error about pointer size being negative |
11:53:33 | * | Araq_ joined #nimrod |
11:54:02 | Araq_ | kokozedman: welcome |
11:54:28 | Araq_ | we regularly build for ARM and powerpc64, no MIPS32 |
11:55:00 | Araq_ | if you can provide some testing machine, I'll update the necessary installers |
11:55:45 | Araq_ | but hey, the better if --cpu:i386 is a possible workaround |
11:55:49 | kokozedman | Araq_: well, it seems that it works on MIPS32 ... it's a very very little example, but the good thing about Nimrod is that it goes down to C, and C compilers are not very hard to come by these days, even for really rare/old routers |
11:56:10 | kokozedman | yes, I am already using that flag to make it compile |
11:56:49 | kokozedman | testing machine ... it's an OpenWrt router that happens to have MIPS32 instruction |
11:57:39 | kokozedman | it's not very practical to have router exposed on the internet ... OpenWrt is kind of widespread, so anyone, including you Araq_ can use it on your own router and you have yourself a "testing machine" |
11:57:57 | kokozedman | just check your router if it's compatible with OpenWrt |
11:58:37 | Araq_ | ok, plus I guess we can always setup a virtual machine |
11:59:13 | kokozedman | Araq_: I don't think there is a proper virtual machine for MIPS32 ... I might be wrong, but there was time I tried to search for that, but I couldn't find |
12:00:19 | Araq_ | ok too bad. what's your OS? |
12:02:05 | Matthias247 | can't qemu to mips32? |
12:03:03 | kokozedman | I develop on Arch Linux, I build the toolchain on it in order to get a GCC that compiles native codes for the router/MIPS32 ... Then, so far (actually just found Nimrod about 2 hours ago) I have just played some short program on the Arch Linux, ensured it worked on the PC, then I created a small bash script that simply calls the GCC/toolchain for the router/MIPS32 in order to generate an executable for the router |
12:03:43 | kokozedman | Matthias247: hmm... I have no idea, never used qemu before |
12:04:05 | Matthias247 | seems like it should: http://www.linux-mips.org/wiki/QEMU |
12:05:01 | kokozedman | wow!... what a finding, it appears that it does indeed |
12:05:44 | kokozedman | my router's CPU matches the one listed on that page: MIPS '24Kc' |
12:08:35 | kokozedman | one thing's for sure: Nimrod appears to work fine on OpenWrt routers ... for all the people out there who's looking for a C/C++ replacement to develop close to metal language that is productivity friendly, Nimrod seems to be an interesting choice |
12:09:18 | Araq_ | btw there is some documentation dealing with cross-compliling |
12:10:00 | Araq_ | http://nimrod-lang.org/nimrodc.html#cross-compilation |
12:10:00 | Matthias247 | kokozedman: do you use it with linux or bare-metal? |
12:10:23 | Araq_ | but unfortunately -gen_script is quite broken these days |
12:11:06 | Trixar_za | Yeah, I noticed QEMU does support a lot of architecture |
12:12:28 | * | kokozedman_ joined #nimrod |
12:12:40 | kokozedman_ | got it ... nice :) |
12:12:55 | * | kokozedman quit (Ping timeout: 246 seconds) |
12:12:56 | kokozedman_ | thanks for these infos |
12:14:53 | Matthias247 | but don't take the "quick" too seriously :) |
12:15:15 | Matthias247 | it's probaby still 10times slower than a native program |
12:20:20 | * | Jehan_ joined #nimrod |
12:24:02 | kokozedman_ | Matthias247: why do you say that? something with the way Nimrod works? |
12:24:35 | Matthias247 | say what? The performance of qemu? |
12:24:59 | Matthias247 | That's just a general statement - has nothing to ddo with nimrod |
12:26:07 | kokozedman_ | well, generally, routers are all really slow compared to PCs ... and this is one reason why Nimrod is an interesting choice because it is a "compiled" language, interpreted language performance on routers are really really slow |
12:31:06 | * | darkf quit (Quit: Leaving) |
12:42:56 | will | when I use the {.Bycopy.} pragma, my objects still seem to be passed by refererence? Am i doing something wrong? |
12:46:58 | will | here is an example: https://gist.github.com/cowboy-coders/1d33b5dfb371f6dd986f |
12:47:48 | * | gkoller quit (Ping timeout: 250 seconds) |
12:57:08 | Jehan_ | will: You're using a `var` parameter, which requires call-by-reference. |
12:57:26 | will | thanks |
13:03:01 | * | Fr4n joined #nimrod |
13:05:12 | will | In a generic proc, is there a way to determine if I can call isNil for a given specialization? I was just going to conditionally assert references weren't nil. |
13:06:31 | Araq_ | when compiles(isNil(x)) |
13:06:38 | will | thanks |
13:07:17 | Araq_ | and don't use ': void' |
13:08:00 | Araq_ | nimrod is not c++ where you constantly have to write things that you don't want |
13:08:09 | kokozedman_ | out of curiosity, why was the name Nimrod chosen? |
13:08:59 | will | thanks for the advice |
13:10:44 | Araq_ | kokozedman_: it was the first king who also happened to build the tower of Babel |
13:11:30 | Araq_ | but we're renaming the language to 'Nim' btw since nobody ever understood the joke |
13:12:19 | kokozedman_ | so, it's based on the Bible? |
13:12:38 | Araq_ | yes |
13:13:03 | will | what was the joke? |
13:23:29 | Jehan_ | will: I guess it'd be this: http://en.wikipedia.org/wiki/Confusion_of_tongues |
13:24:26 | will | thanks, I'll check it out. Is it seriously being renamed, 'Nim', or was that part of the joke? |
13:25:01 | Araq_ | lol |
13:25:50 | will | ahh, I see... It all makes sense now. |
13:26:00 | Araq_ | well we already have the URL if you don't believe me: http://nim-lang.org |
13:26:13 | Trixar_za | Yes, but then we'll have confused 'island of nim' people coming in here |
13:26:14 | will | you guys sure know your biblical references! |
13:26:50 | will | I liked the name Nimrod :D |
13:27:05 | Trixar_za | Well, atleast he didn't name it Lot |
13:28:20 | * | io2 quit (Quit: ...take irc away, what are you? genius, billionaire, playboy, philanthropist) |
13:30:55 | Trixar_za | But for that to work, you'd have to have a fork that turned to crap and two offspring languages that got merged back into main |
13:32:39 | will | it's nothing to do with the 2008 Austrailian adventure-fantasy film, Nim's island, then? |
13:33:26 | Trixar_za | Oh and a backstabbing friend that let you die in a flood |
13:34:16 | * | Boscop__ is now known as Boscop |
13:42:51 | * | Fr4n quit (Ping timeout: 246 seconds) |
13:48:03 | kokozedman_ | hmm... how do I fix this problem: Aporia/aporia.nim(11, 7) Error: cannot open 'glib2' |
13:50:48 | * | saml joined #nimrod |
13:51:09 | Araq_ | install babel and with babel glib2 |
13:55:04 | kokozedman_ | ok, thanks |
13:59:17 | * | Fr4n joined #nimrod |
14:05:12 | * | clone1018_ joined #nimrod |
14:05:46 | Trixar_za | Hey dom96, how did you originally create the bootloader? |
14:11:58 | * | [CBR]Unspoken quit (*.net *.split) |
14:11:59 | * | clone1018 quit (*.net *.split) |
14:11:59 | * | lyro quit (*.net *.split) |
14:11:59 | * | skroll quit (*.net *.split) |
14:16:50 | * | [CBR]Unspoken joined #nimrod |
14:18:08 | * | lyro joined #nimrod |
14:18:54 | * | skroll joined #nimrod |
14:20:11 | kokozedman_ | Araq_: babel install glib2 ... unsuccessful => Error: unhandled exception: Package not found. [EBabel] ... I don't get it |
14:20:34 | Araq_ | babel install gtk2 |
14:21:34 | kokozedman_ | alright ... got it |
14:25:33 | * | gkoller joined #nimrod |
14:29:33 | * | EXetoC joined #nimrod |
14:32:23 | * | gkoller_ joined #nimrod |
14:34:30 | * | gkoller quit (Ping timeout: 260 seconds) |
14:38:29 | kokozedman_ | "Der Mensch ist doch ein Augentier -- schöne Dinge wünsch ich mir" ... what does that say? Google translate doesn't make proper sense |
14:38:48 | * | noam joined #nimrod |
14:41:50 | Araq_ | "Man is an animal of the eye. I wish for beautiful things." or something like that |
14:57:25 | * | gkoller joined #nimrod |
15:07:30 | * | io2 joined #nimrod |
15:12:57 | Jehan_ | I'd translate the first line as "Man is a visual animal". |
15:20:31 | * | kokozedman_ quit (Ping timeout: 246 seconds) |
15:25:09 | * | Fr4n quit (Ping timeout: 240 seconds) |
15:33:43 | * | Boscop quit (Read error: Connection reset by peer) |
15:34:15 | * | Boscop joined #nimrod |
15:34:16 | * | Boscop quit (Changing host) |
15:34:16 | * | Boscop joined #nimrod |
15:38:26 | * | Fr4n joined #nimrod |
15:43:13 | * | Boscop_ joined #nimrod |
15:46:33 | * | Boscop quit (Ping timeout: 240 seconds) |
15:48:49 | * | gkoller quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
15:51:35 | EXetoC | what are some modern, production-ready statically typed languages that are almost as good as nimrod? |
15:56:43 | EXetoC | or better than nimrod, if that is indeed possible ;) |
15:57:59 | Matthias247 | depending on your criteria for "better" it could be basically anything :) |
15:58:27 | Matthias247 | or nothing |
16:00:29 | Araq_ | EXetoC: F#, C#, C++, ML, Haskell, Ocaml, ... ;-) |
16:06:49 | * | brson joined #nimrod |
16:13:28 | * | mwbrown joined #nimrod |
16:16:46 | * | kunev quit (Quit: leaving) |
16:16:57 | * | Fr4n quit (Ping timeout: 245 seconds) |
16:16:59 | EXetoC | C++? never again :p ML? I wonder how good the library support is. Haskell? don't think so. Ocaml? it's a good language with a couple of annoying warts apparently. |
16:17:40 | EXetoC | F# might be a little more interesting than C# I suppose, though I haven't used either. I wonder how many libs are supported on linux though. I'll have to do some research |
16:20:56 | Matthias247 | library support for f# on linux should be the same as for c# |
16:21:02 | Matthias247 | which is quite good |
16:22:46 | * | bjz quit (Quit: Textual IRC Client: www.textualapp.com) |
16:23:56 | will | don't you have to be wary of the community promise... something about how microsoft could sell the patents on? |
16:25:02 | EXetoC | some people claim it's only fearmongering |
16:26:08 | will | I wouldn't like to take the risk ;D |
16:26:14 | Matthias247 | you could also certainly think about Java, Scala or Go. But I guess araq left them out intentionally ;) |
16:27:24 | Araq_ | I didn't |
16:27:37 | EXetoC | Java is another language that I wouldn't want to touch |
16:28:51 | Matthias247 | I think Java8 is quite ok. Not a dream but I can work with it |
16:29:34 | Matthias247 | but it has nothing that c# can't do better ;) |
16:29:39 | EXetoC | and scala also relies on that main-as-a-class-function bullshit, but it's probably much less tedious than Java, so I guess I could overlook that |
16:30:10 | * | Fr4n joined #nimrod |
16:30:22 | Araq_ | well "modern" and "almost as good as nimrod" is highly subjective |
16:30:38 | EXetoC | sure |
16:30:46 | Araq_ | that leaves us with "production-ready statically typed languages" |
16:30:57 | Araq_ | and so Java, Scala and Go count |
16:33:03 | * | gkoller_ quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
16:33:46 | Matthias247 | I think the choice also depends on your project goals and further requirements but also on your team and it's knowlegde\fs26 |
16:34:28 | EXetoC | I'm pretty sure that many of the programmers in here have preferences that I'd agree with |
16:42:21 | Matthias247 | My personal preference when I have no special requirements is c#. But that doesn't help when I have to interface something native, or use a Java lib, or whatever :) |
16:42:56 | * | Boscop_ quit (Read error: Connection reset by peer) |
16:43:00 | Jehan_ | EXetoC: The primary annoyance factor I have with OCaml is that (like C++) it forces you to write interfaces separate from implementations. Other than that, possibly the verbosity of functors. |
16:43:32 | * | Boscop_ joined #nimrod |
16:45:10 | will | I say press ahead using nimrod, fix the bugs as you go ;) |
16:45:11 | EXetoC | yeah ok |
16:45:18 | Jehan_ | Matthias247: Well, P/Invoke is one of the saner ways to interface with native code. |
16:46:10 | Matthias247 | of course, but it still asks for trouble |
16:46:47 | Matthias247 | and then you have to maintain multiple native libraries plus your c# application. In that case a single c++ project might be easier |
16:46:48 | Jehan_ | Matthias247: Yeah, the (relative) ease of interfacing with C in Nimrod is one of its major attractions for me. |
16:48:04 | Jehan_ | For what it's worth, Scala and NImrod are the two languages I am using primarily (when given the choice). |
16:51:03 | Matthias247 | libraries are also a huge decision factor. Scala might be great for writing a web app. But for a user interfaces c++ and c# might offer better support |
16:53:12 | Jehan_ | Matthias247: I'm not using Scala for web apps. |
16:53:53 | Matthias247 | that was just an example of a domain where I think Scala is heavily used at the moment (through Akka and Play) |
16:54:01 | EXetoC | will: the support for things like widget toolkits and (secure) web development is still lacking |
16:54:23 | Araq_ | for UI apps I'd still use Lazarus with a Nimrod backend. Depending on the app though you might not need a "backend" |
16:54:40 | EXetoC | and I barely have any motivation atm when it comes to personal projects. anyway, I consider the language itself to be one of the best |
16:55:35 | Araq_ | too bad that interfacing with FPC is not that easy. (been there, tried that.) |
16:55:36 | EXetoC | I haven't heard of lazarus |
17:00:30 | * | q66 joined #nimrod |
17:04:03 | * | Araq_ quit (Quit: ChatZilla 0.9.90.1 [Firefox 29.0/20140421221237]) |
17:04:45 | * | gsingh93 joined #nimrod |
17:09:23 | * | bjz joined #nimrod |
17:13:13 | * | Trustable joined #nimrod |
17:23:41 | * | gkoller joined #nimrod |
17:24:56 | * | Fr4n quit (Ping timeout: 244 seconds) |
17:25:58 | * | kunev joined #nimrod |
17:26:27 | * | io2 quit (Quit: ...take irc away, what are you? genius, billionaire, playboy, philanthropist) |
17:30:25 | * | io2 joined #nimrod |
17:36:51 | * | Fr4n joined #nimrod |
17:37:43 | EXetoC | any production-ready web frameworks in C? :-) |
17:49:37 | Araq | EXetoC: http://www.reddit.com/r/programming/comments/2dwcny/dyadc_a_lightweight_easy_to_use_asynchronous/ |
18:01:10 | EXetoC | not really a web framework though. KORE maybe. it would of course be better to interface with a C lib rather than having to use another language |
18:01:54 | Araq | not sure what you mean, nim's async+await is stable now |
18:02:03 | Araq | dom96 is porting other modules to use it |
18:02:21 | EXetoC | but then you have things like HTTPS |
18:03:28 | Araq | we support that too |
18:03:35 | EXetoC | I'm just toying with different ideas |
18:13:03 | * | filwit joined #nimrod |
18:14:53 | Araq | hi filwit |
18:15:03 | filwit | hello, Araq |
18:16:13 | dom96 | hello |
18:18:20 | dom96 | EXetoC: C? Why C? |
18:18:40 | EXetoC | because of what I wrote after that |
18:19:30 | dom96 | because you're just toying with different ideas? |
18:19:41 | EXetoC | and then you have things like password hashing, and it's a good idea for people who aren't experts to use high level interfaces made by knowledgeable people |
18:19:51 | EXetoC | no, because you could wrap it |
18:20:30 | dom96 | But Nimrod compiles to C, surely you can wrap it too. |
18:21:27 | EXetoC | as in creating a nimrod wrapper |
18:22:37 | dom96 | oh |
18:22:47 | filwit | I ran my RayTracing multi-threaded benchmark on an i7 (arch linux) last night... very good results (~2sec compared to ~8.4sec single thread). |
18:22:53 | dom96 | You're better off improving Nimrod's async |
18:23:21 | filwit | this is a bit off-topic from what I'm doing right at the moment, but does anyone know a "good practice" way to divide workload by CPU-count? |
18:23:34 | dom96 | Trixar_za: I used GRUB as the bootloader. |
18:24:45 | EXetoC | then what? security does indeed seem like rocket science at times |
18:25:44 | filwit | with the ray-tracer, I found that there's a definite "sweet spot" for the amount of work-load-to-cores ratio, and to keep all cores active the most, it was by spawning about 4*cpuCount |
18:26:03 | filwit | just wondering if there are any multi-threading experts out there |
18:26:04 | dom96 | EXetoC: That's why we're not implementing our own SSL lib |
18:27:38 | * | Ven joined #nimrod |
18:27:58 | Araq | filwit: well in theory threadpool should adapt to the optimum number of working threads |
18:28:10 | EXetoC | well, libs can take care of timing attack issues for example. I don't know what else one needs to be wary of |
18:29:43 | filwit | Araq: the problem is if i just divided the work across 4 spawns (one for each core of my cpu), then some cores would complete much fast than others, and remain idle for a long time (causing the overall time to be more than if i divided the workload up more). |
18:30:09 | filwit | Araq: of course, maybe this isn't so much a "how many cores" but a "how large a task" problem... |
18:31:38 | filwit | Araq: although, it might also be nice if there was some sort of async response protocol ThreadPool would call when a thread completed (instead of just `sync()`)? That way you could keep all cores active by waiting to spawn more until others are done. |
18:32:05 | filwit | Araq: a bit out of my depth here though, so I'm not sure if that's a good idea or not. |
18:32:54 | EXetoC | dom96: it seems like a good idea to be very pedantic when it comes to security, if anything |
18:33:12 | dom96 | EXetoC: well then you should simply use Ada |
18:33:48 | EXetoC | or any language with plenty of industry support? |
18:34:28 | Araq | filwit: that already should work when you return something |
18:34:55 | Araq | then you can do var foo = spawn f(a); echo(^foo) |
18:36:31 | Araq | or awaitAny |
18:37:12 | filwit | Araq: interesting. Is there more examples of ThreadPool somewhere? I see there's no docs.. but i kinda remember a blog post awhile ago you did? |
18:37:26 | Araq | no, it's too new |
18:37:31 | filwit | k, np |
18:37:48 | Araq | however, for your case I think what you're doing is optimal |
18:38:02 | Araq | aka measuring and hardcoding stuff |
18:38:27 | filwit | yeah, i'm just thinking beyond the ray-tracer |
18:38:34 | filwit | for game-engine stuff |
18:38:41 | EXetoC | dom96: such as python or any of the other popular languages, but I don't know how hard it is to create secure web apps using only core technologies such as SSL and bcrypt directly |
18:38:50 | * | Jesin joined #nimrod |
18:39:10 | filwit | where the tasks aren't so clear-cut |
18:39:12 | EXetoC | what about ada? does it have suitable libs? |
18:39:37 | Araq | Ada is a PITA for everything non-embedded, IMHO |
18:39:59 | filwit | Araq: but this isn't what I'm working on, and the ray-tracer works well with what's there, so I'll revisit the ThreadPool stuff once documentation is more available. |
18:40:04 | EXetoC | I don't know why I should use it then :p |
18:40:28 | Araq | because it's very safe :P |
18:43:44 | EXetoC | I suppose I don't have to care *that* much |
18:44:52 | Araq | filwit: I'm no expert but I'd have 1 thread per logical "task" (sound, keyboard handling, ...) and then some heavy tasks use 'parallel' |
18:47:13 | filwit | Araq: keyboard handling, UI, etc is usually done on the main thread, while "best practice" afaik is to create thread jobs for physics, animations, sound (if it requires 3d spacial processing), etc.. so yeah, you're pretty much right. |
18:47:20 | dom96 | EXetoC: Unless you're making software for a multi-million dollar airliner there is no reason not to use Nimrod :P |
18:49:30 | Araq | the API needs to support setting thread affinities. This can significantly reduce jitter |
18:50:04 | EXetoC | dom96: I was indeed focusing on library support |
18:50:45 | filwit | Araq: i'll be experimenting with a lot of different ways to optimize things, but one issue with games is that you only have a 16-32ms window to complete everything... so time it takes to create/sync threads is more of an issue, unlike the ray-tracer which requires seconds regardless |
18:54:38 | Araq | filwit: spawn doesn't create a thread, but it's still not exactly cheap |
18:55:49 | Araq | and there is little we can do about it, there is only so much you can do with thread local heaps |
18:57:06 | filwit | it seems pretty fast, really. It's just a threading problem in general when you usually want to complete a task in 15ms |
18:58:25 | filwit | ThreadPool seems to work very well. The overhead seems minimal (i compared with a low-res image, which completed much faster, and the thread overhead didn't seem to be a problem) |
18:58:44 | * | Boscop_ is now known as Boscop |
18:58:49 | Araq | yay |
19:07:40 | * | Ven quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
19:14:01 | EXetoC | dom96: well, do you know what I need? SSL and bcrypt probably. what else? though, what about HTTPS support for jester? |
19:14:41 | dom96 | EXetoC: Just put nginx in front of jester |
19:16:25 | EXetoC | ok |
19:20:30 | Araq | filwit: you should really blog about your ray tracer and nim's spawn |
19:22:15 | filwit | Araq: sure, I will try and come up with something.. |
19:22:41 | Araq | great |
19:29:19 | EXetoC | Araq: ok so 'window.document.bgColor = "#FF0000"' should resolve to 'document.bgColor = "#FF0000"'. how? |
19:29:33 | EXetoC | this is regarding the dom module in case it wasn't clear |
19:30:04 | Araq | no idea, it's been years since I wrote it |
19:31:02 | EXetoC | no wait |
19:31:45 | EXetoC | yeah it is. there's window.document as well as a global document var. that might just be a shortcut |
19:32:20 | dom96 | https://developer.mozilla.org/en-US/docs/Web/API/Window.document |
19:32:41 | dom96 | both exist in the browser I think |
19:33:30 | EXetoC | yeah, gotta run it in an actual browser |
19:34:10 | EXetoC | I've barely used js |
19:35:27 | dom96 | hrm https://realsenseappchallenge.intel.com |
19:38:15 | * | flaviu joined #nimrod |
19:40:15 | EXetoC | "var node_8447 = document.getElementsByTagName("body")[0]" ok so this ends up being null |
19:41:17 | EXetoC | and lastJSError is undefined. bleh |
19:52:37 | * | Jehan_ quit (Quit: Leaving) |
19:53:34 | * | Ven joined #nimrod |
19:56:35 | filwit | EXetoC: i'm not sure about "document.bgColor = '...'" but be careful reading MSDN on the subject, as they sometimes tell you IE specific things (and don't warn you about the incompatibility with other browsers) |
19:57:15 | filwit | EXetoC: an alternative to setting the background color: "document.body.style.background = '#fff'" |
19:57:34 | * | ome quit (Quit: Connection closed for inactivity) |
19:58:07 | dom96 | oh! I just got an idea. |
19:58:19 | dom96 | Compile-time CSS selectors. |
19:58:23 | * | kunev quit (*.net *.split) |
19:58:23 | * | icebattle quit (*.net *.split) |
19:58:24 | * | Kelet quit (*.net *.split) |
19:58:29 | filwit | dom96: old idea :P |
19:58:43 | * | icebattle joined #nimrod |
19:58:54 | filwit | dom96: they have languages which "compile" to CSS that support inheritance, constants, etc |
19:59:08 | filwit | dom96: although I've never really used them |
19:59:20 | dom96 | That's not what i'm talking about. |
19:59:30 | filwit | yeah... i see that now... |
19:59:32 | dom96 | $("#id > .class") |
19:59:55 | dom96 | Could be transformed into document.getElementById("id").getElementsByClass("class") |
20:00:12 | dom96 | which would be faster than parsing the CSS at runtime, which I am assuming is what jQuery does. |
20:01:36 | filwit | yep... actually making a good JS backend lib which basically mimics jQuery wouldn't be a bad idea |
20:02:06 | * | Kelet joined #nimrod |
20:03:02 | filwit | hmm... one of the added benefits is that you can code in one language for both server/client (like Dart) and get type-safety, compile-time checks, etc. So that might actually be a pretty popular idea. |
20:03:51 | dom96 | yep |
20:03:55 | dom96 | That is what I want to make. |
20:04:57 | filwit | dom96: what would be pretty cool actually.. is making something like Concrete5 in Nim, plus some JS backend libs |
20:05:24 | filwit | Concrete5: http://www.concrete5.org/ |
20:05:46 | filwit | it's the CMS i |
20:05:51 | filwit | ...'ve always used |
20:06:26 | filwit | but it's PHP, and not the most efficient (on slower servers you can really feel the impact) |
20:06:26 | * | untitaker quit (Ping timeout: 255 seconds) |
20:07:02 | dom96 | oh look, a new D release. |
20:07:16 | filwit | yeah i saw that |
20:07:18 | Araq | also a release of C++14 |
20:07:24 | filwit | that too |
20:07:37 | filwit | looks like we all are browsing reddit instead of working.... |
20:07:40 | filwit | lol |
20:08:19 | dom96 | I do it almost subconsciously now. |
20:08:38 | dom96 | I should just get a second monitor and have it scroll, matrix style. |
20:09:46 | dom96 | hrm, that's a good idea actually. |
20:10:10 | filwit | lol... |
20:10:48 | dom96 | My todo file is too big :( |
20:11:16 | Matthias247 | with the difference that c++ is only a spec release and the implementation will follow ... later |
20:11:33 | * | ehaliewicz joined #nimrod |
20:11:38 | * | untitaker joined #nimrod |
20:15:18 | flaviu | Matthias247: https://isocpp.org/blog/2014/08/we-have-cpp14 |
20:15:18 | flaviu | "For C++98, the delta between publishing the standard and the first fully conforming implementation being available was about 5 years. For C++11, it was two years. For C++14, the two have merged and we have achieved “time on target.”" |
20:16:02 | Matthias247 | flaviu: visual studio 2013 still has no full c++11 support. So there is for sure no c++14 in it today :) |
20:16:22 | Matthias247 | even if gcc might support it |
20:16:34 | flaviu | Why would anyone use microsoft's compiler? |
20:16:34 | Araq | clang and gcc both do support it |
20:16:52 | Araq | flaviu: it comes with a good IDE, that's why |
20:16:54 | flaviu | yeah, and I hear that both clang and gcc are faster than msvc |
20:17:00 | Araq | nope |
20:17:16 | Araq | last time I checked msvc was fastest |
20:17:40 | flaviu | Araq: clang has a msvc api |
20:17:45 | flaviu | so its a drop-in replacement |
20:17:48 | Matthias247 | flaviu: it has the best IDE and because windows is still the most-used plattform |
20:18:03 | Araq | flaviu: it's also a defacto standard |
20:18:12 | * | ehaliewicz quit (Ping timeout: 260 seconds) |
20:18:15 | flaviu | Araq: "drop-in replacement" |
20:18:33 | flaviu | clang does all the non-standard stuff msvc does |
20:18:40 | Matthias247 | gcc on windows is crap. And clang can only recently build "native" windows executables. Not very sure if it's mature |
20:18:40 | flaviu | same commandline, etc too |
20:18:47 | Araq | without even bothering to look I can assure you Unreal 4 has some .sln file that you can use |
20:19:51 | Matthias247 | --> when you want to build a native application for windows that your business depends on there's no way around visual studio |
20:19:59 | filwit | Araq: i've had a different experience with MVC vs GCC... but maybe I didn't benchmark anything extensive (we have a C++ version of the ray-tracer) |
20:20:52 | filwit | Araq: what's odd.. is that GCC 4.8.2 on Windows ran my RayTracer ~40ms faster than GCC 4.9 on Linux (Nim version)... |
20:20:58 | flaviu | Anyway, it looks like msvc and gcc are about tied, maybe msvc comes out a little bit ahead |
20:21:08 | flaviu | filwit: Try clang? |
20:22:28 | Matthias247 | if you use gcc on windows you need msys or cygwin. And nobody wants that |
20:22:41 | Araq | well msvc also has a shitty / not existant effect analysis last time I checked |
20:22:50 | filwit | flaviu: clang on Linux runs ~20ms slower than GCC (single threaded), but I don't have LLVM/Clang setup on Windows yet |
20:23:33 | filwit | flaviu: if you do, just clone the ray-tracer and try it out.. i'll be interested to know the results if you do |
20:23:44 | Araq | it's hard to make general statements, they are all quite on par until you come up with micro benchmarks where one compiler failed to produce good code |
20:23:59 | flaviu | filwit: Link? |
20:24:13 | flaviu | I don't know your github username |
20:24:17 | filwit | https://github.com/zezba9000/RayTraceBenchmark |
20:24:27 | filwit | i'm not zezba9000, that's my brother |
20:24:30 | filwit | btw |
20:24:42 | Araq | does clang support OpenMP now, flaviu ? |
20:25:12 | filwit | Araq: yes... but not sure about the release version |
20:25:18 | flaviu | Since 3.1 it looks like |
20:26:09 | Araq | took clang a while to get support for it |
20:26:15 | filwit | flaviu: the Nimrod test is obviously in the 'Nimrod' folder... it'll output a '.rgb' image (which you can open with Photoshop, or convert with 'convert ..' on linux) |
20:26:41 | flaviu | filwit: how do I time it? Just `time`? |
20:26:47 | flaviu | oh, nm |
20:26:55 | * | Ven quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
20:27:02 | filwit | flaviu: no it'll output it's own benchmark numbers (in seconds) |
20:27:25 | flaviu | I lost in in the nimrod -c outputs, thanks |
20:27:31 | flaviu | *it |
20:27:47 | filwit | flaviu: i just added multi-threading support... compare -d:{release,bigImg} to -d:{release,bigImgMT} --threads:on |
20:28:38 | filwit | flaviu: you can also add -d:noSave to avoid it saving a huge image to your disk (bigImg saves a 720p*8 resolution image) |
20:28:49 | filwit | which is like 10k by 5k |
20:29:24 | filwit | 10,000x5,000 pixels i mean |
20:30:24 | flaviu | I hope I can make room for that giant 2.8MB image, I might run out of hard drive space :P |
20:31:29 | filwit | flaviu: just letting you know... i run the test a lot, and only need it to save once (to verify it works) |
20:31:45 | filwit | but yeah... not much of a deal |
20:33:14 | filwit | flaviu: what do the results look like? |
20:33:28 | filwit | flaviu: i mean performance results (not image) |
20:33:41 | flaviu | Well, I haven't gotten very far yet |
20:33:48 | filwit | ah, okay |
20:33:57 | flaviu | single core clang is .24 |
20:34:27 | filwit | everyone's CPUs are faster than min :( |
20:34:34 | filwit | mine* |
20:34:54 | flaviu | I have the 965, 3.2Ghz :P |
20:35:02 | flaviu | Just barely faster than your's |
20:35:09 | filwit | ah, okay |
20:35:21 | filwit | my brother's i7 is pretty quick |
20:35:33 | filwit | ~2x times faster than mine |
20:35:37 | flaviu | I hear that this model overclocks great, but I still use stock cooler, so I don't know |
20:36:04 | filwit | yeah i don't trust over-clocking stuff... would prefer stable |
20:37:38 | dom96 | Varriount_: https://gist.github.com/dom96/e854c71ce4dcd759a913 |
20:38:04 | filwit | anyways, since you have pretty much the same CPU as mine (just a bit faster) than I expect the result to be pretty similar in the multi-threaded test... probably ~16sec with -d:bigImg and ~4sec with -d:bigImgMT |
20:40:32 | * | gkoller quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
20:42:34 | * | Ven joined #nimrod |
20:43:23 | flaviu | filwit: Please review PR #1 |
20:44:34 | filwit | one sec |
20:46:18 | flaviu | Ah, I think it may be incorrect |
20:46:46 | filwit | hmm... i would prefer it if that only happened when you -d:useAverage or something |
20:47:48 | filwit | i think it's correct tho |
20:47:48 | flaviu | Its incorrect anyway, I never clear the pixmap |
20:48:14 | filwit | why would you need to clear it though? it just rewrites the data.. |
20:48:50 | filwit | err... that's not correct at all... your epochTime() is not inside the loop |
20:49:07 | flaviu | It shouldn't be inside the loop |
20:49:20 | flaviu | I'm assuming that the overhead of a branch and add is nothing |
20:49:31 | flaviu | I think the overhead of epoch time is greater |
20:49:36 | filwit | ah, okay |
20:52:37 | flaviu | Ok, I'll just put it behind a when |
20:52:47 | filwit | hmm... just so we're not out-of-sync here, how about we put that behind a `when not defined(singleRun)`... and by that I mean you might as well do it to yours before i accept the PR |
20:53:29 | filwit | thanks |
20:56:52 | filwit | flaviu: also, can you put the 20 under a const at the top (or inside main)? |
20:57:02 | flaviu | Sure |
20:57:22 | filwit | thanks |
21:00:19 | flaviu | filwit: Ok, done. I've cleaned it up, there only needs to be a single define for the runs constant |
21:01:20 | filwit | great. let me know when you make a PR |
21:02:02 | flaviu | I already did |
21:02:05 | flaviu | https://github.com/zezba9000/RayTraceBenchmark/pull/1 |
21:03:11 | filwit | whoops... was looking at your repo for a sec and didn't see a PR... doh |
21:04:08 | flaviu | It looks like nimrod doesn't like the scene variable: 'spawn'ed function cannot refer to 'ref'/closure |
21:04:56 | filwit | flaviu: can you completely remove the 'runs' variable, and not even do a for loop when averageRuns is not defined, please? |
21:06:04 | flaviu | I'd be surprised if it wasn't optimized out, but ok. |
21:06:18 | filwit | flaviu: just do `let time = when defined(averageRuns): (end-start) / runs else: (end-start)` after the test completes or something |
21:06:43 | dom96 | Interesting to see how split the Python community is for this proposition of including the mypy static typing syntax. |
21:14:52 | flaviu | filwit: Ok, done |
21:18:53 | Araq | dom96: we're doing something very wrong ... |
21:19:08 | Araq | this python 2/3 split, now optional static typing |
21:19:27 | Araq | and yet nobody flees over to nim |
21:19:43 | * | gsingh93 quit (Quit: Connection closed for inactivity) |
21:19:58 | dom96 | Yeah. You're right, we need to get rid of static typing. |
21:20:21 | flaviu | dom96: Please not another language extension... |
21:20:45 | flaviu | that's completely possible as code, and the compiler is much too complicated as-is |
21:21:13 | dom96 | flaviu: another? |
21:21:39 | dom96 | I'm kidding though. |
21:21:57 | dom96 | But that reminds me, I attempted to create a macro which mimics python a while ago. |
21:22:06 | dom96 | Can't remember why I gave up on that. |
21:22:27 | flaviu | You don't need macros for loose typing |
21:23:35 | dom96 | of course not, but they make the code look sexy. |
21:24:16 | flaviu | simple > complicated |
21:25:10 | * | Ven quit (Ping timeout: 264 seconds) |
21:25:14 | dom96 | The stargazers beg to differ: https://github.com/dom96/jester |
21:25:35 | dom96 | Cool. PyConIreland retweeted my tweet. |
21:26:24 | flaviu | They aren't staring because they like the macros, they're staring because jester is the only game in town. |
21:26:44 | Araq | flaviu: I agree completely that we don't need more features. Well except for the planned missing stuff ofc :P |
21:28:39 | dom96 | flaviu: Yes, having no competition helps. But it's the code that is shown in the readme that wins people over. |
21:29:28 | flaviu | hmm, ok, although that macro I'm sure is very simple |
21:32:12 | dom96 | I guess. It's not as simple as no macro at all. |
21:32:32 | dom96 | It makes the code look a lot more appealing though. |
21:33:02 | dom96 | than: j.addRoute("/", proc (req: PRequest) = ..) |
21:35:46 | flaviu | My feature suggestions are more important and useful than everyone else's, for example `(x, y, z): ...` should desugar to an anon proc |
21:35:52 | * | Ven joined #nimrod |
21:39:03 | EXetoC | don't we have similar sugar? |
21:39:10 | Araq | flaviu: lol |
21:40:39 | * | Trustable quit (Quit: Leaving) |
21:45:09 | * | Ven quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
21:48:27 | dom96 | flaviu: still busy? |
21:48:56 | * | dom96 still wants a vindinium starter pack |
21:49:18 | flaviu | dom96: Sorry, I have other things to do |
21:49:28 | * | Ven joined #nimrod |
21:49:32 | filwit | flaviu: merged your PR, thanks. But I'm changing on minor minor thing (you didn't remove the brackets around elapsedTime :P) |
21:49:53 | flaviu | oh, I didn't think of that. Thanks |
21:50:18 | dom96 | flaviu: what other things are those? |
21:50:42 | flaviu | Well, schoolwork, and I'm figuring out how to write a typechecker |
21:50:51 | flaviu | also, I'm doing benchmarks for filwit |
21:51:14 | dom96 | schoolwork? It's summer time. |
21:51:30 | flaviu | not for me lol |
21:51:52 | flaviu | Since 2 weeks ago |
21:52:41 | dom96 | Oh my god. I've heard of places like this, where the school year starts in August. Until now I thought they were a myth... |
21:53:00 | * | dom96 gasps in horror |
22:06:12 | * | seubert_ joined #nimrod |
22:11:00 | * | lyro quit (Ping timeout: 246 seconds) |
22:11:01 | * | seubert quit (Ping timeout: 246 seconds) |
22:11:02 | * | OrionPK quit (Ping timeout: 246 seconds) |
22:11:46 | Varriount_ | dom96: I have to live with that horror too. |
22:11:56 | filwit | flaviu: just pushed a change to the ray-tracer (just so you know). You're right, the `for i in 1 .. runs:` looked better.. thought it wouldn't but was wrong. Also adjusted some other minor things but it's mostly just personal style preferences. |
22:12:05 | * | lyro joined #nimrod |
22:12:15 | dom96 | Varriount_: Are you back at Uni already? |
22:12:36 | Varriount_ | I go back on Wednesday |
22:12:41 | * | Varriount_ is now known as Varriount |
22:12:54 | Varriount | dom96: I'm reading your notes, I'll respond in a bit. |
22:13:08 | dom96 | Varriount: I start at the end of September lol |
22:15:06 | filwit | flaviu: oh... and i changed the define to 'avgRuns' instead (since i'm using 'Img' abbr anyways, thought it made sense and I prefer the shorter name)... i will add a readme.md to the folder later to explain things. Thanks for your contribution. |
22:15:22 | flaviu | Sure, no problem |
22:15:50 | flaviu | filwit: btw, I finished benchmarking and sent a PR |
22:16:42 | * | Ven quit (Read error: Connection reset by peer) |
22:17:11 | filwit | Awesome, thanks :) I've been meaning to bench on my Rasberry Pi for awhile now.. guess I don't have to anymore. |
22:17:58 | flaviu | The rasbian results aren't mine, git just diffs weird |
22:18:29 | filwit | oh yeah wait... i did that awhile ago i think... |
22:18:41 | filwit | brain is not working well today apparently |
22:19:04 | * | mwbrown quit (Ping timeout: 260 seconds) |
22:19:28 | filwit | flaviu: you don't use GCC at all? |
22:19:45 | Varriount | Ok, dom96, my responses: |
22:19:46 | filwit | oh, no nevermind.... the MD file doesn't format well |
22:19:51 | filwit | hrm... |
22:20:03 | Varriount | dom96: Yes, there was a linux version that *you* wrote, that's still in the standard library - You charged me with writing a *windows* version. We've had this talk before. |
22:20:08 | dom96 | Varriount: Put them in a gist |
22:20:13 | dom96 | i'm too tired to process them lol |
22:21:11 | dom96 | I can reply to that: I assumed you would merge them together. |
22:21:35 | dom96 | and you've got comments about other platforms in there |
22:23:29 | Varriount | dom96: That was in expectation. |
22:40:09 | Varriount | dom96: https://gist.github.com/Varriount/2373d90f6499d55dcf3c |
22:45:41 | filwit | flaviu: heads-up, formatted your results better and added readme instructions |
22:46:56 | flaviu | thanks |
22:47:06 | Varriount | What are you two cooking up> |
22:47:09 | Varriount | *? |
22:47:41 | filwit | Varriount: he benchmarked and contributed to the ray-tracer: https://github.com/zezba9000/RayTraceBenchmark/tree/master/Nimrod |
22:47:45 | dom96 | Varriount: The solution is to capture the info you need in your closure. (In regards to the last point) |
22:47:48 | Varriount | :D |
22:48:05 | flaviu | Benchmarks for raytracing |
22:48:42 | Varriount | dom96: Yes, but I have to spawn multiple overlapped structures. |
22:49:04 | dom96 | Varriount: That shouldn't be a problem |
22:49:30 | Varriount | So I would need to store them in a sequence captured by the closure. How's that different to capturing them in a watchData object stored in a seq? |
22:50:26 | dom96 | Varriount: I don't think vars are captured by ref in closures. |
22:50:52 | Varriount | dom96: Can you give me a line number? |
22:51:24 | dom96 | or maybe they are |
22:51:42 | dom96 | In any case, you will be creating a new watch data object anyway. |
22:52:04 | * | OrionPK joined #nimrod |
22:52:57 | Varriount | dom96: What about doing what the asyncdispatch code does, and extending the overlapped structure? |
22:54:30 | dom96 | You can do that, but you shouldn't need to capture it in your callback. |
22:54:39 | dom96 | The asyncdispatch callbacks do not capture the overlapped object. |
22:54:44 | Varriount | Capture what, the overlapped structure? |
22:55:01 | dom96 | yes |
22:55:04 | Varriount | dom96: But I have to call readDirectoryChangesW *with* an overlapped structure. |
22:55:44 | dom96 | So you're reusing overlapped structures? |
22:56:03 | dom96 | You should just create a new one in the callback if you want to call readDirectoryChanges inside it. |
22:56:39 | Varriount | dom96: Could we talk on teamspeak? I feel like it might be easier to explain. |
22:57:00 | dom96 | ok, give me a sec |
23:09:01 | * | io2 quit (Quit: ...take irc away, what are you? genius, billionaire, playboy, philanthropist) |
23:09:14 | * | mko joined #nimrod |
23:10:53 | Araq | hi mko welcome |
23:11:19 | mko | Hi, Araq. Thanks. |
23:13:05 | * | Boscop quit (Changing host) |
23:13:05 | * | Boscop joined #nimrod |
23:19:03 | * | Matthias247 quit (Read error: Connection reset by peer) |
23:24:28 | Araq | good night |
23:27:45 | * | darkf joined #nimrod |
23:31:46 | * | flaviu quit (Ping timeout: 255 seconds) |
23:35:49 | * | flaviu joined #nimrod |
23:38:09 | * | brson_ joined #nimrod |
23:39:24 | * | brson_ quit (Client Quit) |
23:39:38 | * | brson_ joined #nimrod |
23:40:33 | * | brson quit (Ping timeout: 240 seconds) |