boilingsteam, to linux
@boilingsteam@mastodon.cloud avatar
cpponline, to cpp

What’s New in Compiler Explorer? 2024 Update – by @mattgodbolt – C++Online 2024

https://www.youtube.com/watch?v=28Gp3TTQYp0

bread80, to random
@bread80@mstdn.social avatar

I've renamed the EXTERN directive to CALL. That feels a lot more logical given it's function (to call assembly code such as ROM routines).

It also makes it straightforward to implement an RST directive to call assembly via a Z80 RST instruction.

(In the screenshot I've cleaned up the comments in the output to make it easier to read.)

#Quiche #compiler #Z80 #Delphi

bread80, to random
@bread80@mstdn.social avatar

#Compiler update: Write and writeln marks the end of the the refactoring of operations and primitives which has taken up the last few months.

I've also refactored a few other parts to better future proof them.

There a still a few rough edges to smooth off in the expression parser (implicit types) and code generator (parameter loading and validation).

But this means I can now return to interesting stuff :) as well as moving towards some kind of initial (pre-beta) release.

#Quiche #Z80

Output if the test program running on an Amstrad CPC emulator.

FrankauLux, to random French
@FrankauLux@mastodon.social avatar
jesper, to haskell
@jesper@agda.club avatar

This is a great blog post on the WellTyped blog on specialization in Haskell! It's a good reminder that I (or someone) should really get around to getting rid of -fexpose-all-unfoldings and -fspecialize-agressively in the Agda codebase.

well-typed.com/blog/2024/04/choreographing-specialization-pt1/

(Also I didn't know about -flate-specialise and -fpolymorphic-specialisation, though I think I'd rather avoid relying on even more flags.)

#Haskell #compiler #performance #blog

janriemer, to Blog
hywan, to PostgreSQL
@hywan@fosstodon.org avatar

Look ma, […] a new JIT compiler for PostgreSQL, https://www.pinaraf.info/2024/03/look-ma-i-wrote-a-new-jit-compiler-for-postgresql/.

The author explains how he is writing a new JIT compiler for PostgreSQL. The author uses a technics described in https://arxiv.org/pdf/2011.13127.pdf, called copy-patch. It’s an old idea with a new name, but it’s fun.

#PostgreSQL #jit #compiler #performance #sql

hywan, to rust
@hywan@fosstodon.org avatar

How I [the author of the article] reduced (incremental) Rust compile times by up to 40%, https://www.coderemote.dev/blog/faster-rust-compiler-macro-expansion-caching/.

The idea is pretty simple but clever: cache the output of proc macros, if it hasn’t changed, no need to recompile the associated code.

The author explains the caveat of this approach as not all proc macros are pure.

#RustLang #compiler #performance #macros

janriemer, to random

While I'm rewriting my #transpiler from #nom to #chumsky, I'm actually thinking about writing a nom-to-chumsky transpiler...

➰ 🙃

#Compiler

aburka,
@aburka@hachyderm.io avatar

@janriemer call it Nom Chumsky's Universal Grammar

janriemer,

@aburka Lol, this is absolutely brilliant!😅 :awesome: 🎉

janriemer, to showerthoughts

Feature request for code editors:

Command for jumping to the next file that has #compiler errors.

#Code #CodeEditor #Idea #Feature #Editor #LSP

bread80, to random
@bread80@mstdn.social avatar

I apologise for not posting this earlier.

is now alive! (At least Conway's variant of alive). The initial version was slow - about four seconds per generation. It was multiplying coordinates for each cell read and write.

The second variant uses offsets into each liner buffer, and only redraws changed cells. It's now running at three to four generations per second.

The next generation of the glider.

RetroFunPL,
@RetroFunPL@8bit.red avatar

@bread80
i never realized Quiche has so few semicolons

bread80,
@bread80@mstdn.social avatar

@RetroFunPL The syntax isn’t fully formed yet, but semicolons will be optional. It will use line endings as end of statement markers instead. Code can be split across lines either with an explicit \ character or if it ends with an incomplete expression.

One of a couple of features I’m taking from Ruby. A language which, mostly, makes very sensible choices.

bread80, to random
@bread80@mstdn.social avatar

This week I added the Peek() and Poke() intrinsics to the . That means I can now write my first non-trivial program.

I spend this morning fixing a few bugs in the parser and code generator and it's successfully generating the assembler file.

The assembler is choking on a couple of issues with identifiers, and the output code has a couple of bugs to do with parameter parsing and result processing.

Very close to working <g>

A section of the output assembler code.

bread80,
@bread80@mstdn.social avatar

The compiler doesn't have arrays yet, so I'm using pointers to memory and Peek and Poke - hence why they're useful.

I also don't have any kind of memory management. I'm hard coding addresses which I know won't clobber anything.

I have to work around a few other missing features and bugs. It'll be interesting to see the code develop as the compiler develops.

And the same for the code generation. It's still deeply naive with plenty of potential for even basic improvements.

bread80,
@bread80@mstdn.social avatar

Looks like all the known bugs are squashed.

Now onto deployment ... it's a while since I've built for anything other than the emulator/raw binary.

I changed the deployment system after the last time I built for WinApe. And previously doing such builds was clunky. In theory the new deployment system should make this a lot easier.

fell, to cpp
@fell@ma.fellr.net avatar

C++ compiler be like:

error LNK2001: unresolved external symbol "public: static class std::unordered_map&lt;class std::basic_string&lt;char,struct std::char_traits&lt;char&gt;,class std::allocator&lt;char&gt; &gt;,unsigned int,struct std::hash&lt;class std::basic_string&lt;char,struct std::char_traits&lt;cha r&gt;,class std::allocator&lt;char&gt; &gt; &gt;,struct std::equal_to&lt;class std::basic_string&lt;char,struct std::char_traits&lt;char&gt;,class std::allocator&lt;char&gt; &gt; &gt;,class std::allocator&lt;struct std::pair&lt;class std::basic_string&lt;char,struct std::char_traits&lt;char&gt;,class std::allocator&lt;char&gt; &gt; const ,unsigned int&gt; &gt; &gt; TextureStore::texture_cache" (?texture_cache@TextureStore@@2V?$unordered_map@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IU?$hash@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@2@U?$equal_to@V?$basic_string@DU?$char_traits @D@std@@V?$allocator@D@2@@std@@@2@V?$allocator@U?$pair@$$CBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@I@std@@@2@@std@@A)

And expect me to casually read that and go "Ah, I see".

#cpp #cplusplus #cpp20 #programming #compiler #error

CodingThunder,
@CodingThunder@mastodon.social avatar

@fell once you get used to it, you can go through it in like 5 sec and figure out what's wrong

fell,
@fell@ma.fellr.net avatar

@CodingThunder I found the issue immediately. But I won't ever get used to this. I've been a full-time C++ programmer for six years now. I will never get used to this.

fell, to programming
@fell@ma.fellr.net avatar

Good morning everyone ☕

fatal error C1001: Internal compiler error.  
error D8040: error creating or communicating with child process  

MSVC agrees: It sure is a monday.

#msvc #programming #cpp #cpp20 #cplusplus #compiler #microsoft

  • All
  • Subscribed
  • Moderated
  • Favorites
  • JUstTest
  • mdbf
  • ngwrru68w68
  • InstantRegret
  • magazineikmin
  • thenastyranch
  • rosin
  • khanakhh
  • tacticalgear
  • Youngstown
  • slotface
  • Durango
  • kavyap
  • DreamBathrooms
  • anitta
  • ethstaker
  • GTA5RPClips
  • modclub
  • tester
  • provamag3
  • osvaldo12
  • cisconetworking
  • everett
  • cubers
  • normalnudes
  • megavids
  • Leos
  • lostlight
  • All magazines