Re: Building LDC runtime for a microcontroller

2020-09-23 Thread Dylan Graham via Digitalmars-d-learn
On Wednesday, 23 September 2020 at 10:02:58 UTC, Dylan Graham wrote: On Friday, 18 September 2020 at 07:44:50 UTC, Dylan Graham wrote: On Monday, 7 September 2020 at 19:12:59 UTC, aberba wrote: On Monday, 7 September 2020 at 16:18:00 UTC, IGotD- wrote: On Monday, 7 September 2020 at 15:23:28 UT

Re: Building LDC runtime for a microcontroller

2020-09-23 Thread Denis Feklushkin via Digitalmars-d-learn
Wow, I have just received a link to this topic from my colleague. Here is also another thread about druntime for MCUs: https://forum.dlang.org/post/cwtkntyjhrwvpahfk...@forum.dlang.org

Re: Building LDC runtime for a microcontroller

2020-09-23 Thread Dylan Graham via Digitalmars-d-learn
On Friday, 18 September 2020 at 07:44:50 UTC, Dylan Graham wrote: On Monday, 7 September 2020 at 19:12:59 UTC, aberba wrote: On Monday, 7 September 2020 at 16:18:00 UTC, IGotD- wrote: On Monday, 7 September 2020 at 15:23:28 UTC, Severin Teona wrote: [...] Use betterC, which is much better su

Re: Building LDC runtime for a microcontroller

2020-09-20 Thread Dylan Graham via Digitalmars-d-learn
On Sunday, 20 September 2020 at 15:13:25 UTC, Steven Schveighoffer wrote: On 9/20/20 10:51 AM, Dylan Graham wrote: On Saturday, 19 September 2020 at 20:39:38 UTC, aberba wrote: Do you attend our monthly D online meetups? We have monthly online meetups? I would love to join of course! Happen

Re: Building LDC runtime for a microcontroller

2020-09-20 Thread Dylan Graham via Digitalmars-d-learn
On Saturday, 19 September 2020 at 23:22:50 UTC, IGotD- wrote: On Friday, 18 September 2020 at 07:44:50 UTC, Dylan Graham wrote: I use D in an automotive environment (it controls parts of the powertrain, so yeah there are cars running around on D) on various types of ARM Cortex M CPUs, I think

Re: Building LDC runtime for a microcontroller

2020-09-20 Thread Steven Schveighoffer via Digitalmars-d-learn
On 9/20/20 10:51 AM, Dylan Graham wrote: On Saturday, 19 September 2020 at 20:39:38 UTC, aberba wrote: Do you attend our monthly D online meetups? We have monthly online meetups? I would love to join of course! Happening next weekend! 🍻 https://forum.dlang.org/post/rjjcl4$30sm$1...@digitalm

Re: Building LDC runtime for a microcontroller

2020-09-20 Thread Dylan Graham via Digitalmars-d-learn
On Saturday, 19 September 2020 at 20:39:38 UTC, aberba wrote: On Friday, 18 September 2020 at 07:44:50 UTC, Dylan Graham wrote: On Monday, 7 September 2020 at 19:12:59 UTC, aberba wrote: [...] [...] Wow. Happy to hear this. Do you attend our monthly D online meetups? We have monthly onli

Re: Building LDC runtime for a microcontroller

2020-09-19 Thread IGotD- via Digitalmars-d-learn
On Friday, 18 September 2020 at 07:44:50 UTC, Dylan Graham wrote: I use D in an automotive environment (it controls parts of the powertrain, so yeah there are cars running around on D) on various types of ARM Cortex M CPUs, I think this will be the best way to extend D to those platforms.

Re: Building LDC runtime for a microcontroller

2020-09-19 Thread aberba via Digitalmars-d-learn
On Friday, 18 September 2020 at 07:44:50 UTC, Dylan Graham wrote: On Monday, 7 September 2020 at 19:12:59 UTC, aberba wrote: [...] I use D in an automotive environment (it controls parts of the powertrain, so yeah there are cars running around on D) on various types of ARM Cortex M CPUs, I t

Re: Building LDC runtime for a microcontroller

2020-09-19 Thread Imperatorn via Digitalmars-d-learn
On Monday, 7 September 2020 at 22:13:20 UTC, Adam D. Ruppe wrote: On Monday, 7 September 2020 at 20:55:54 UTC, IGotD- wrote: [...] Well, -betterC existed even then, but it was *completely* useless. It didn't become useful until 2016 or 2017. [...] Cool!

Re: Building LDC runtime for a microcontroller

2020-09-19 Thread Johan via Digitalmars-d-learn
On Friday, 18 September 2020 at 23:00:33 UTC, Adam D. Ruppe wrote: The error says something about constness being different, well, why the eff would an init symbol ever be mutable? See https://forum.dlang.org/post/edngcvtlkjpykxvxy...@forum.dlang.org for why TypeInfo is mutable. (In this ca

Re: Building LDC runtime for a microcontroller

2020-09-18 Thread Adam D. Ruppe via Digitalmars-d-learn
On Thursday, 17 September 2020 at 09:53:57 UTC, Remi wrote: My problem here is mostly understanding the __initZ symbol and where it comes from. The compiler generates that when it spits out something that uses TypeInfo, which is a lot of things: ~= and ~ operators on built in arrays, the new

Re: Building LDC runtime for a microcontroller

2020-09-18 Thread Dylan Graham via Digitalmars-d-learn
On Monday, 7 September 2020 at 19:12:59 UTC, aberba wrote: On Monday, 7 September 2020 at 16:18:00 UTC, IGotD- wrote: On Monday, 7 September 2020 at 15:23:28 UTC, Severin Teona wrote: [...] Use betterC, which is much better suited for microcontrollers than the full D. The disadvantage is tha

Re: Building LDC runtime for a microcontroller

2020-09-18 Thread Remi via Digitalmars-d-learn
On Thursday, 17 September 2020 at 19:27:41 UTC, Adam D. Ruppe wrote: fyi my baby was just born i'll come back to this but it might be a day or two Oh probably most unexpected answer! Congratulations! Had 4 weeks myself, take care of your family, everything else can wait ;)

Re: Building LDC runtime for a microcontroller

2020-09-17 Thread H. S. Teoh via Digitalmars-d-learn
On Thu, Sep 17, 2020 at 08:40:06PM +, wjoe via Digitalmars-d-learn wrote: > On Thursday, 17 September 2020 at 19:27:41 UTC, Adam D. Ruppe wrote: > > fyi my baby was just born i'll come back to this but it might be a > > day or two [...] "A day or two"??! More likely a month for starters. :-D

Re: Building LDC runtime for a microcontroller

2020-09-17 Thread wjoe via Digitalmars-d-learn
On Thursday, 17 September 2020 at 19:27:41 UTC, Adam D. Ruppe wrote: fyi my baby was just born i'll come back to this but it might be a day or two congratulations! All the best for your family :)

Re: Building LDC runtime for a microcontroller

2020-09-17 Thread Adam D. Ruppe via Digitalmars-d-learn
fyi my baby was just born i'll come back to this but it might be a day or two

Re: Building LDC runtime for a microcontroller

2020-09-17 Thread Remi via Digitalmars-d-learn
On Thursday, 17 September 2020 at 09:53:57 UTC, Remi wrote: [snip] My problem here is mostly understanding the __initZ symbol and where it comes from. I mostly want classes and the bare minimum of std like you did for Tetris in WebAssembly for example. My project is OpenGL/SDL2 so there's a l

Re: Building LDC runtime for a microcontroller

2020-09-17 Thread Remi via Digitalmars-d-learn
On Wednesday, 16 September 2020 at 18:34:05 UTC, Adam D. Ruppe wrote: On Wednesday, 16 September 2020 at 17:59:41 UTC, Remi wrote: I tried to modify the hello.d example from your blog post. It works without changes but when I tried to do a string concatenation Yeah, concatenation is one of th

Re: Building LDC runtime for a microcontroller

2020-09-16 Thread Adam D. Ruppe via Digitalmars-d-learn
On Wednesday, 16 September 2020 at 17:59:41 UTC, Remi wrote: I tried to modify the hello.d example from your blog post. It works without changes but when I tried to do a string concatenation Yeah, concatenation is one of the features that uses druntime, and specifically, it is done through Ty

Re: Building LDC runtime for a microcontroller

2020-09-16 Thread Remi via Digitalmars-d-learn
On Monday, 7 September 2020 at 22:13:20 UTC, Adam D. Ruppe wrote: On Monday, 7 September 2020 at 20:55:54 UTC, IGotD- wrote: I guess this was written before betterC existed. Well, -betterC existed even then, but it was *completely* useless. It didn't become useful until 2016 or 2017. But ar

Re: Building LDC runtime for a microcontroller

2020-09-07 Thread Adam D. Ruppe via Digitalmars-d-learn
On Monday, 7 September 2020 at 20:55:54 UTC, IGotD- wrote: I guess this was written before betterC existed. Well, -betterC existed even then, but it was *completely* useless. It didn't become useful until 2016 or 2017. But around that same time, going minimal runtime got even easier, so I n

Re: Building LDC runtime for a microcontroller

2020-09-07 Thread IGotD- via Digitalmars-d-learn
On Monday, 7 September 2020 at 19:12:59 UTC, aberba wrote: How about an alternative runtime + standard library for embedded systems...with a least bare minimum. I've seen a number of efforts to get D to run in those environments but almost none of them is packaged for others to consume. Ada

Re: Building LDC runtime for a microcontroller

2020-09-07 Thread aberba via Digitalmars-d-learn
On Monday, 7 September 2020 at 16:18:00 UTC, IGotD- wrote: On Monday, 7 September 2020 at 15:23:28 UTC, Severin Teona wrote: [...] Use betterC, which is much better suited for microcontrollers than the full D. The disadvantage is that many great features are disabled in betterC. [...] Ho

Re: Building LDC runtime for a microcontroller

2020-09-07 Thread kinke via Digitalmars-d-learn
On Monday, 7 September 2020 at 15:23:28 UTC, Severin Teona wrote: CMake Error at /snap/cmake/549/share/cmake-3.18/Modules/CMakeTestCCompiler.cmake:66 (message): This is apparently a non-LDC specific issue, a default CMake C compiler sanity check fails. When looking at that file, you'll see th

Re: Building LDC runtime for a microcontroller

2020-09-07 Thread IGotD- via Digitalmars-d-learn
On Monday, 7 September 2020 at 15:23:28 UTC, Severin Teona wrote: I would also appreciate any advice regarding ways to build or create a small runtime for microcontrollers (runtime that can fit in the memory of a microcontroller). Thank you very much, Teona [1]: https://wiki.dlang.org/Buildi