Category: Open Source
Andy Wingo: a whiff of whiffle
A couple nights ago I wrote about a superfluous Scheme
implementation
and promised to move on from sheepishly justifying my egregious behavior in
my next note, and finally mention some results from this experiment.
Well, no: I am back on my bullshit. Tonight I write about a couple of
implementation details that discerning readers may find of interest:
value representation, the tail call issue, and the standard library.
what is a value?
As a Lisp, Scheme is one of the early “dynamically typed” languages.
These days when you say “type”, people immediately think propositions
as
types,
mechanized proof of program properties, and so on. But “type”
has another denotation which is all about values and almost not at all
about terms: one might say that
vector-ref has a type, but
it’s not part of a proof; it’s just that if you try to vector-ref a
pair instead of a vector, you get a run-time error. You can imagine
values as being associated with type tags: annotations that can be
inspected at run-time for, for example, the sort of error that
vector-ref will throw if you call it on a pair.
Scheme systems usually have a finite set of type tags: there are
fixnums, booleans, strings, pairs, symbols, and such, and they all have
their own tag. Even a Scheme system that provides facilities for
defining new disjoint types (define-record-type et al) will implement these via a secondary type tag layer: for example that all record
instances are have the same primary tag, and that you have to retrieve
their record type descriptor to discriminate instances of different
record types.
Anyway. In Whiffle there are immediate types and heap types. All values
have a low-bit tag which is zero for heap objects and nonzero for
immediates. For heap objects, the first word of the heap object has
tagging in the low byte as well. The 3-bit heap tag for pairs is chosen so that
pairs can just be two words, with no header
word.
There is another 3-bit heap tag for forwarded objects, which is used but the
GC when evacuating a value. Other objects put their heap tags in the low 8
bits of the first word.
Additionally there is a “busy” tag word value, used to prevent races
when evacuating from multiple threads.
Finally, for generational collection of objects that can be “large” —
the definition of large depends on the collector implementation, and is
not nicely documented, but is more than, like, 256 bytes — anyway these
objects might need to have space for a “remembered” bit in the object
themselves. This is not the case for pairs but is the case for, say,
vectors: even though they are prolly smol, they might not be, and they
need space for a remembered bit in the header.
tail calls
When I started Whiffle, I thought, let’s just compile each Scheme
function to a C function. Since all functions have the same type, clang and gcc will have
no problem turning any tail call into a proper tail call.
This intuition was right and wrong: at optimization level -O2, this
works great. We don’t even do any kind of loop recognition /
contification: loop iterations are tail calls and all is fine. (Not the
most optimal implementation technique, but the assumption is that for
our test cases, GC costs will dominate.)
However, when something goes wrong, I will need to debug the program to
see what’s up, and so you might think to compile at -O0 or -Og. In
that case, somehow gcc does not compile to tail calls. One time while
debugging a program I was flummoxed at a segfault during the call
instruction; turns out it was just stack overflow, and the call was
trying to write the return address into an unmapped page. For clang, I
could use the musttail
attribute;
perhaps I should, to allow myself to debug properly.
Not being able to debug at -O0 with gcc is annoying. I feel like if GNU were an actual thing, we would have had the equivalent of a musttail attribute 20 years ago already. But it’s not, and we still don’t.
stdlib
So Whiffle makes C, and that C uses some primitives defined as inline
functions.
Whiffle actually lexically embeds user Scheme
code
with a
prelude,
having exposed a set of
primitives
to that prelude and to user code. The assumption is that the compiler
will open-code all primitives, so that the conceit of providing a
primitive from the Guile compilation host to the Whiffle guest magically
works out, and that any reference to a free variable is an error. This
works well enough, and it’s similar to what we currently do in
Hoot
as well.
This is a quick and dirty strategy but it does let us grow the
language to something
worth using. I think I’ll come back to this local maximum later if I
manage to write about what Hoot does with modules.
coda
So, that’s Whiffle: the Guile compiler front-end for Scheme, applied to
an expression that prepends a user’s program with a prelude, in a
lexical context of a limited set of primitives, compiling to very simple
C, in which tail calls are just return f(...), relying on the C
compiler to inline and optimize and all that.
Perhaps next up: some results on using Whiffle to test Whippet. Until
then, good night!
F-Droid Alphas and good news for CJK users
TWIF generated on Thursday, 16 Nov 2023, Week 46
F-Droid core
F-Droid Basic and F-Droid were updated to 1.19.0-alpha1
as development continues. Note that this is still in beta so brave users need to install this manually (enable Beta updates for the app or from Client expert settings).
Community News
@Licaon_Kter highlights that Orgzly Revived was newly added, and as its name spells it out, it’s a fork of Orgzly that appeared out of necessity given that Orgzly’s main developer has not been seen for the last year. We hope @Neven if fine and safe!
As announced last week Arcticons Dark, Arcticons Light and Arcticons You were updated to 8.0.6
so you can now enjoy more than 8000 icons. And if your favourite app is not yet in, do ask for it!
@Vasyl Gello shared with us that RustDesk was updated to 1.2.3-1
bringing significant changes like:
- Hardware keyboard support for Android: now you can use your favourite mechanics paired to your phone to control other desktops, servers or even phones!
- Updated libraries: fixes CVE-2023-5217 and several other security vulnerabilities exploited in the wild.
- Builds for all 4 platforms: arm, arm64, x86 and x86_64. Rustdesk becomes F-Droid’s first submission built with Flutter framework on 32-bit x86 Android.
- Automated update support: new versions will be built automatically as soon as new upstream version becomes public!
Small note from @Licaon_Kter: RustDesk currently is flagged with the Tracking antifeature, but Vasyl promised they’re on track to fix that so F-Droid users get the chance to use their remote devices in a privacy-friendly way!
@rocka let us know that Fcitx5 for Android (and its plugins) have been updated to 0.0.8
. Fcitx5 is a generic input method framework on Linux, the Android port includes virtual keyboard with customizable color scheme, clipboard management, as well as plugin support for adding more languages. English and Chinese (Pinyin, Wubi, Cangjie) are bundled within the application. Two plugins got updated this release:
- Anthy: Japanese input method based on anthy-unicode
- Clipboard Filter: strip tracking parameters from URLs in clipboard
And 6 more are now available:
@linsui comments: Fcitx5 Android 0.0.8 is an exciting update for CJK users! The input methods apps are very important – without them you can’t input anything. English users maybe didn’t notice this since they can use the keyboard shipped with AOSP and there are many other keyboards like AnySoftKeyboard in F-Droid which support many more languages. However, CJK users have had much less choices, specially in F-Droid. We only had two general IME apps for Chinese users: Trime and Lime. There are few other apps supporting specific schemes. For Japanese users, there were only two choices: OpenWnn and Mozc Android, both of which are not maintained anymore, unfortunately. And we had no IME app for Korean users nor Sinhala users. Then what app were they using? Maybe GBoard was their only choice. But now the situation has changed! Fcitx5 Android brings many input methods to F-Droid and, since 0.0.8, most plugins available on Linux desktop are also available on Android. Besides that, as a input method framework, it’s much easier to develop a new input method for Android with it. So, if you’re stuck with GBoard, please give Fcitx5 a try!
Removed Apps
5 apps were removed
Como was no longer able to download words from its server.
Curator, LifeHQ and Wrotto are no longer developed, so their developer asked the team for them to be archived.
YARR’s repo was archived by its developer and it is no longer actively maintained.
Small note from @Licaon_Kter: Some of the apps were archived because users reported them to the F-Droid team, so if you see an app that suddenly misbehaves, fails to run, to connect to its services or otherwise malfunction, feel free to open an issue so the team can investigate and take measures as needed.
Newly Added Apps
6 more apps were newly added
- Bible Verse App
- FREE Browser
- Flip a coin
- LiveWallpaperIt – Muzei plugin for Reddit
- NiDeau
- Pirate Solitaire
Updated Apps
149 more apps were updated
- 2048 Open Fun Game was updated from
1.12.0
to1.14.3
- AAAAXY was updated from
1.4.72+20231030.3091.de20c129
to1.4.101+20231111.3120.29c354f1
- AF Weather Widget was updated from
2.3
to2.4
- AirGuard – AirTag protection was updated from
2.1
to2.1.1
- Amethyst was updated from
0.80.4
to0.80.7
- AndBible: Bible Study was updated from
5.0.742
to5.0.755
- APK Explorer & Editor was updated from
v0.27
tov0.28
- Audile was updated from
1.1.0
to1.1.3
- AusweisApp was updated from
1.26.7
to2.0.0
- BetterUntis was updated from
4.0.2
to4.0.3
- Bimba was updated from
3.1.0
to3.1.1
- blocker was updated from
2.0.2976-fdroid
to2.0.3058-fdroid
- Boxcars was updated from
1.0.8
to1.1.1
- Burger Party was updated from
1.4.2
to1.4.3
- Cache Cleaner was updated from
1.8.4
to1.8.6
- Calculator++ was updated from
2.2.7
to2.3.3
- CameraAlign was updated from
3.0
to3.1
- Casio G-Shock Smart Sync was updated from
10.7
to11.0
- Chaldea was updated from
2.4.20
to2.5.0
- Chip Defense was updated from
1.22
to1.26
- Copy SMS Code – OTP Helper was updated from
1.6.0
to1.7.0
- CPU Stats was updated from
2.1.5
to2.2.0
- croc was updated from
1.10.12
to1.10.13
- Crossword was updated from
1.22
to4.4.199
- Currency was updated from
1.55
to1.56
- Dark theme was updated from
2.5
to2.6
- Databag was updated from
1.0
to1.1
- DataStats was updated from
2.8.2
to2.8.3
- Diary was updated from
1.102
to1.103
- DPC was updated from
1.1.0
to1.2.0
- DuckDuckGo Privacy Browser was updated from
5.175.1
to5.177.1
- Editor was updated from
1.89
to1.90
- EinkBro was updated from
10.15.0
to10.16.1
- ente – encrypted photo storage was updated from
0.7.102
to0.7.108
- Every Door was updated from
4.0.0
to4.1.0
- EVMap – EV chargers was updated from
1.7.0
to1.7.1
- FairEmail was updated from
1.2118
to1.2123
- Feeder was updated from
2.6.7-1
to2.6.8
- Fennec F-Droid was updated from
119.0.0
to119.1.0
- FluffyChat was updated from
1.15.0
to1.15.1
- Forkgram was updated from
10.2.3.0
to10.2.6.0
- FOSS Warn was updated from
0.5.1
to0.6.0
- FreePaint was updated from
1.0.2
to1.1.0
- Gallery for PhotoPrism was updated from
1.20.3
to1.21.0
- Gauguin was updated from
0.9.4
to0.10.0
- GPSLogger was updated from
127
to129
- gptAssist was updated from
1.20
to1.30
- Graded – Grade tracker was updated from
2.4.2
to2.5.0
- Gridle was updated from
1.15
to1.16
- Groestlcoin Wallet was updated from
10.03
to10.07
- Groestlcoin Wallet TestNet was updated from
10.03
to10.07
- Hacki for Hacker News was updated from
2.2.0
to2.3.1
- Hamfisted was updated from
0.1.3
to0.1.4
- Handy Reading was updated from
0.18.18
to0.19.7
- Harmony Music was updated from
1.5.0
to1.6.0
- HK Transport was updated from
1.0.1
to1.0.2
- idTech4A++ was updated from
1.1.0harmattan33natasha
to1.1.0harmattan35natasha
- Immich was updated from
1.84.0
to1.85.0
- Inner Breeze was updated from
1.0.1
to1.0.8
- Inure App Manager (Trial) was updated from
Build94
toBuild95
- Inventory was updated from
1.0.5
to1.0.6
- Invoice Ninja was updated from
5.0.138
to5.0.139
- IYPS was updated from
1.4.2
to1.4.3
- Joplin was updated from
2.13.5
to2.13.6
- jtx Board journals¬es&tasks was updated from
2.06.01.ose
to2.06.03.ose
- KitchenOwl was updated from
0.4.13
to0.4.14
- Kotatsu was updated from
6.2.6
to6.2.7
- Library App VideLibri was updated from
2.752
to2.765
- Librera Reader was updated from
8.9.46-fdroid
to8.9.58-fdroid
- Linux Command Library was updated from
3.2.2
to3.2.3
- Linwood Flow was updated from
0.2.0
to0.2.1
- LMS was updated from
0.4.1
to0.4.2
- Logcat was updated from
2.0
to2.1
- LogFox was updated from
1.4.9
to1.5.0
- Markdownr was updated from
1.5.1
to1.6.0
- Massive was updated from
1.167
to1.185
- Metronome was updated from
1.4.3
to1.4.4
- Minesweeper – Antimine was updated from
17.5.1 F
to17.5.10 F
- monocles chat was updated from
1.7.5
to1.7.7.2
- Mull was updated from
119.0.0
to119.1.0
- MuPDF mini was updated from
1.23.4a
to1.23.5a
- MuPDF viewer was updated from
1.23.4a
to1.23.5a
- Musify was updated from
6.6.0
to6.7.1
- NetGuard was updated from
2.324
to2.325
- Nextcloud Cookbook was updated from
0.14.4
to0.14.5
- Nextcloud Dev was updated from
20231102
to20231114
- NextDNS Manager was updated from
4.7.12
to4.8
- Notes was updated from
1.37
to1.38
- NOVA Video Player was updated from
6.2.33
to6.2.34
- Offi was updated from
12.1.13-aosp
to12.1.14-aosp
- Oinkoin was updated from
1.0.22
to1.0.23
- OpenDNS Updater was updated from
2.2.3
to2.2.4
- OpenVPN for Android was updated from
0.7.49
to0.7.50
- Opus 1 Music Player was updated from
2.61.2
to2.61.3
- Pachli was updated from
1.3.0
to1.4.0
- PasswdSafe was updated from
6.23.1
to6.23.3
- Persian Calendar was updated from
8.3.6
to8.4.0
- PhotoChiotte was updated from
1.45
to1.46
- Pie Launcher was updated from
1.14.1
to1.14.2
- PlainApp: File & Web Access was updated from
1.2.10
to1.2.11
- Podverse was updated from
4.14.2
to4.14.3
- Prepaid Balance was updated from
2.3
to2.4
- ProtonVPN – Secure and Free VPN was updated from
4.8.32.1
to4.8.38.0
- psychphinder was updated from
1.1.2
to1.1.3
- QRAlarm was updated from
1.5.8
to1.5.10
- QR Scanner (PFA) was updated from
4.3.1
to4.4.0
- Railway station photos was updated from
15.0.2
to15.0.3
- Retro Stack was updated from
0.2.4
to0.2.5
- Revengate was updated from
0.10.0
to0.11.0
- SatDump was updated from
1.1.1
to1.1.2
- Sayboard was updated from
v4.1.0
tov4.1.1
- Seeneva: smart comic reader was updated from
0.1.1-fdroid
to0.1.2-fdroid
- SerialPipe was updated from
v0.0.1
tov0.0.2
- Shitter was updated from
3.4.5
to3.4.6
- Signal Generator was updated from
1.34
to1.35
- SilverDict was updated from
1.0.6
to1.1.0
- Simlar – secure calls was updated from
2.9.4 (alwaysOnline)
to2.10.0 (alwaysOnline)
- SimpleTextEditor was updated from
1.24.1
to1.24.2
- Smart AutoClicker was updated from
2.3.5
to2.3.6
- Specie was updated from
1.12
to1.13
- SpMp was updated from
0.2.3
to0.2.4
- Squircle CE – Code Editor was updated from
2023.1.5
to2023.2.0
- Stopwatch was updated from
1.2
to1.3
- Stroke Input Method (筆畫輸入法) was updated from
1.2.6
to1.2.7
- Sudoku (Privacy Friendly) was updated from
3.1
to3.1.1
- Symphony was updated from
2023.8.105
to2023.11.106
- Syncthing-Fork was updated from
1.23.6.0
to1.26.0.2
- Syncthing was updated from
1.23.7
to1.26.0
- Table Habit was updated from
1.9.1
to1.9.2
- Tabletop Tools was updated from
1.23
to1.24
- Tailscale was updated from
1.51.207-t35d7b3aa2-g3a305b158ca
to1.53.115-t6cce5fe00-gab4a672a4eb
- Taler Wallet was updated from
0.9.3+p9
to0.9.3+p10
- taz was updated from
1.7.4
to1.8.0
- Telegram FOSS was updated from
10.1.1
to10.2.6
- The Light was updated from
3.71
to3.72
- TorrServe was updated from
MatriX.126.2.F-Droid
toMatriX.127.F-Droid
- Tuner was updated from
1.53
to1.54
- Tuta Mail was updated from
3.118.22
to3.118.27
- Unciv was updated from
4.8.16
to4.8.18
- URLSanitizer was updated from
2.0.3
to2.1.0
- Vespucci was updated from
19.2.4.0
to19.3.1.0
- Voyager for Lemmy was updated from
1.20.1
to1.23.2
- wallabag was updated from
2.4.3
to2.5.0
- WG Tunnel was updated from
3.2.0
to3.2.1
- Wikipedia was updated from
r/2.7.50455-r-2023-10-10
tor/2.7.50458-r-2023-11-09
- Wulkanowy was updated from
2.2.5
to2.2.6
- Xtra was updated from
2.26.0
to2.26.1
- Zulip was updated from
27.217
to27.218
- μlogger was updated from
3.9
to3.10
Thank you for reading this week’s TWIF 🙂
Please subscribe to the RSS feed in your favourite RSS application to be updated of new TWIFs when they come up.
You are welcome to join the TWIF forum thread if you have any news from around the community, maybe it will be featured next week 😉
NetBox Tutorial: How to Add Dummy Inventory Data Into NetBox
Video by via Dailymotion Source Welcome back to IEE! In today’s tutorial, how we could add dummy data inventory into NetBox. What You’ll Learn:• ️ WARNING: The steps of this video is only intended for a Lab Environment not the production environment.• ️ Setting Up Dummy Data: Learn the step-by-step process of adding dummy inventory…
Una Dosis Diaria de Sol Capitulo 8 Español Audio Latino : Doramas en Audio Latino
Video by via Dailymotion Source Una noble enfermera de la unidad de Psiquiatría lo da todo para ser el rayo de luz que necesitan sus pacientes, a pesar de las dificultades que se cruzan en el camino. OP1 : https://doramasonlinelatino.blogspot.com/2023/11/una-dosis-diaria-de-sol-daily-dose-of.htmlOP2 : https://doramaslatinox.blogspot.com/2023/11/una-dosis-diaria-de-sol-daily-dose-of.htmlOp3 : https://doramasenestrenolatino.blogspot.com/2023/11/una-dosis-diaria-de-sol-daily-dose-of.htmlOp4 : https://doramaexpress.com/series/una-dosis-diaria-de-sol/ Una Dosis Diaria de Sol Capitulo 8 Español Audio…
Can’t Help Falling in Love – Elvis Presley | EASY Guitar Tutorial with Chords / Lyrics
Video by via Dailymotion Source Can’t Help Falling in Love – Elvis Presley | EASY Guitar Tutorial with Chords / Lyrics and Strumming Patterns ↓ ↓ Chords ↓ ↓https://guitarintensivechord.blogspot.com/2023/02/cant-help-falling-in-love-elvis-presley.html ↓ ↓ Instrumental Melody ↓ ↓https://youtu.be/0DYDTf7N7gI?si=-VKfL–_ZZqTct9e Thanks for WatchingPlease don’t forget to Like, Share, and Subscribe in my Channel for more Easy Guitar Tutorial Video See…
Q-Qaida – Episode 35 – Learn Quran – 16 Nov 2023 – ARY Qtv
Video by via Dailymotion Source Q-Qaida – Episode 35 – Learn Quran – Hafiza Urooj Iqbal – 16 Nov 2023 – ARY Qtv Teacher: Hafiza Urooj Iqbal Class: 35 | Tanveen aur Murakkab Huroof #QQaida #HafizaUroojIqbal #ARYQtv #QuranEducation Q Qaida is an introductory program that teaches beginners how to read the Arabic Script for Quranic…
Korku Dolu Gece – Half life 2 Bölüm #5
Video by via Dailymotion Source Ayrıcalıklardan yararlanmak için bu kanala katılın:https://www.youtube.com/channel/UCpcHFJwDFlrnbCw3yD-4Wzg/join CANIM HANDAŞ AİLEM BİZLERİ DESTEKLEDİĞİNİZ HER GÜN GELEN VİDEOLARIMIZI İZLEYİP LİKE ve YORUM ATTIĞINI İÇİN HEPİNİZE SONSUZ TEŞEKKÜR EDİYORUM.SİZLER SAYESİNDE BURADAYIZ VE SİZLER SAYESİNDE HEDEFİMİZE ULAŞACAĞIZ 10 MİLYON HANDAŞ AİLESİNE ULAŞMAK İÇİN ELİMİZDEN GELENİ YAPACAĞIZ.SİZLERDE HANDAŞ AİLEMİZE KATILMAYI VE BİZLERE DESTEK VERMEYİ LÜTFEN UNUTMAYIN—————————————————————————————————————————————-–…