Profile

Cover photo
Martin Geisler
843 followers|8,750,981 views
AboutPostsCollectionsPhotosVideosReviews

Stream

Martin Geisler

Shared publicly  - 
 
Nice little website for people who aren't familiar with string formatting in Python!
Python has had awesome string formatters for many years but the documentation on them is far too theoretic and technical. With this site we try to show you the most common use-cases covered by the old and new style string formatting API with practical examples. All examples on this page work out ...
1
1
Add a comment...

Martin Geisler

Shared publicly  - 
 
Martin Ockajak will be giving a talk about Haskell and Scala and how the two languages compare with each other. Sounds like fun!
3
Add a comment...

Martin Geisler

Shared publicly  - 
 
I just updated to the newly released Go 1.7 and recompiled our project at work. The build time dropped by almost 60%! Wow, kudos to the Go team for this!

I simply ran "rm -r $GOPATH/pkg && time make build" to test this. I ran the above tests a few times and the before and after results were stable. I'm on a Mac at work and it was a simple "brew update && brew upgrade" to get the new version. 
Go 1.7 is released. 15 August 2016. Today we are happy to announce the release of Go 1.7. You can get it from the download page. There are several significant changes in this release: a port for Linux on IBM z Systems (s390x), compiler improvements, the addition of the context package, ...
3
Add a comment...

Martin Geisler

Shared publicly  - 
 
I've been working with a MacBook since the beginning of July... so far I'm amazed at how annoying it is coming from Linux! I know a lot of great developers who use Macs so I figured it would be an easy switch :-) I miss several features in the core window handling in Mac OS:

Window switching, not application switching. In Linux (and Windows) the usual window managers allow you to switch between windows of different applications without raising all windows of that application.

This is particularly annoying when it comes to terminals: in Linux I would have 3-4 terminal emulators open at any given time and switch between them and my editor with Win-Tab. In Mac OS that's not how things work: when you switch between the editor and the terminal app, all terminal windows are raised. That makes it practically impossible to use more than one terminal window.

Move and resizing windows using the mouse. Most window managers I know in Linux lets you move a window by holding Alt and dragging the window from anywhere. They also usually allow you to resize a window by holding Alt and middle-dragging from anywhere in the window. If you start dragging in the lower-left quadrant of the window, you resize it as if you had dragged in the lower-left corner. A simple and very effective way to make the target for a resize much bigger than just the corner.

In Mac OS that's not a builtin feature. Instead you have to resort to third-party tools, which apparently all want some small amount of money for you. The whole ecosystem is turned upside down: easy small features like this become extra "premium" features and more complicated features like a "genie effect" while minimizing become standard features.

Easy clipboard manipulation. Linux or rather the X Window System has a concept of a selection. When you select text in any window, it's put on a clipboard. You paste that with a middle-click somewhere. It's again a fast power user feature that I was using all the time. That doesn't seem to exist in Mac OS, at least not outside terminal emulators like iTerm.
2
Jim Hague's profile photoMartin Geisler's profile photoChristian Müller's profile photo
8 comments
 
> But I'm sure I'll get used to it — or maybe I'll just install Linux in a VM and run that in fullscreen mode :-D

I did this @ Software AG too, because this was the first time I landed on a windows machine in years — this worked quite well :)

My issue with HDPI was a very inconsistent upscaling across apps and even elements of the same WM! I didn't bother to tweak it though — it was exact the reason I switched to Mac OS, which "just worked" back then :)
Add a comment...

Martin Geisler

Shared publicly  - 
 
The Memory Model of Go and Friends

Very interesting article about the concept of benign data races and whether they exist at all. It turns out that languages like Go doesn't really have benign data races at all and that any race should be considered undefined behavior in the extreme sense: anything can happen, including running random code.

As I understand it, benign data races are basically the kind of races you can find in multi-threaded Python programs. There's no reordering of reads or writes, multiple reads of the same variable cannot be merged, and there's no registers to spill anywhere. In other words, the result of the execution might depend on the random scheduling of the threads, but the observed results of the execution order must be sequentially consistent (https://en.wikipedia.org/wiki/Sequential_consistency).

So you can have a lost update if multiple threads execute

counter += 1

simultaneously (one thread could read the counter before the incremented value is written to it). In no case can you read a value from counter that wasn't written to it at some point in the past — there can be no garbage read.

However, most languages use a more relaxed memory model which allows for more aggressive compiler optimizations. The price is less predictable behavior when there is a data race. Java uses a memory model (http://docs.oracle.com/javase/specs/jls/se8/html/jls-17.html) by which some surprising thing can happen due to reordering, but I don't think you can end up reading arbitrary data. That's pretty nice.

Languages like Go, C and C++ give no guarantees when races occur. As far as I understand, basically anything can happen. The article gives one example of how thing can be terrible wrong when a compiler decides to use the space for a variable as scratch space — register spilling — before the variable is actually written to. In that case, before the write, the variable can contain basically arbitrary data. If another thread reads from that variable, it can thus see garbage data that the programmer never wrote there.

I wonder how much it would cost in performance if the compiler were not allowed to do these optimizations. That is, no random writing to variables. I'm not talking about enforcing a full memory barrier for every non-local read or write, I'm simply talking about not reusing the memory for anything else. I think that is more or less what Java's memory model dictates and to me that sounds like a very sane middle ground between strict sequential consistency and complete mayhem.
The peril of data races. Shows how even the most innocent ones can break badly.
1
Add a comment...

Martin Geisler

Shared publicly  - 
 
Beautiful and powerful illustration of evolution in bacteria! In just 11 days, the E. coli bacteria mutate to be able to survive in an environment with 1000 as much antibiotics as would normally be enough to kill it.
1
1
Add a comment...

Martin Geisler

Shared publicly  - 
 
 
Yes, there is now a "fake" short fingerprint for my kernel signing key out there on the key servers, and yes, it's not really mine, and yes, we know who did it, and yes, it's revoked, and no, it wasn't just targeted at kernel developers, but at all 24000 keys in the "strong" ring of PGP trust, and yes something like this has been possible for a very long time now so it's not really that much news, and yes, gpg really is horrible to use and almost impossible to use correctly.

See the top comment here for more details:
https://news.ycombinator.com/item?id=12296974

And of course, read the evil32.com site for loads of details.

I guess I should be happy that people are checking the signature of my kernel releases, and emailing me that something is "wrong" on their system, that's nice to see. Too bad their scripts are "wrong" as they pull in all keys with a possible 32bit signature and things go boom.

Short answer, always use "long" keys when using gpg, and never auto-refresh keys from the keyservers.
GPG usage has grown steadily while the tooling that supports it remains stagnant despite staggering hardware advancement. 32bit key ids were reasonable 15 years ago but are obsolete now. Using modern GPUs, we have found collisions for every 32bit key id in the WOT's (Web of Trust) strong set.
15 comments on original post
3
1
Add a comment...

Martin Geisler

Shared publicly  - 
 
How technology sometimes feels these days... :-)
Hey, my boss said to talk to you - I hear you know a lot about web apps?-Yeah, I’m more of a distributed systems guy now. I’m just back from ContainerCamp and Gluecon and I’m going to Dockercon next week. Really excited about the way the industry is moving - making everything simpler and more reliable. It’s the future!
2
Add a comment...

Martin Geisler

Shared publicly  - 
 
My new colleague Christian just showed me an old project he did some years ago: a quick and easy to use pastebin for Markdown notes. Looks awesome and very useful for quickly sharing notes with a bit of nice formatting.
Changelog. 2016-08: Syntax highlighting for code blocks added (thanks to Maciej). 2016-03: Note deletion feature added. 2015-10: NoteHub rewritten in Node.js. 2015-10: NoteHub API and note styling discontinued due to low adoption. 2014-09: text size setting added; 2014-07: deprecated all API ...
2
1
Add a comment...

Martin Geisler

Shared publicly  - 
 
Brilliant analysis of Trump by Trevor Noah :-)
3
Add a comment...

Martin Geisler

Shared publicly  - 
 
Some background on the tradeoffs made when Go was designed.
Abstract. (This is a modified version of the keynote talk given by Rob Pike at the SPLASH 2012 conference in Tucson, Arizona, on October 25, 2012.) The Go programming language was conceived in late 2007 as an answer to some of the problems we were seeing developing software infrastructure at ...
1
1
Radomir Dopieralski (deshipu)'s profile photoMartin Geisler's profile photo
2 comments
 
Yes, that sounds about right — they often say they came up with the idea of Go during one 45 minute compile of a big C++ program :-)
Add a comment...
Martin's Collections
Collections Martin is following
Work
Occupation
Software Engineer
Story
Tagline
Open source enthusiast and Mercurial developer
Basic Information
Gender
Male
Small and cozy place with great food! Their pepper steak was delicious, as was their grilled sea fruit.
Public - a week ago
reviewed a week ago
Great place with live music most nights! You can get something to eat (they have okay burgers) and something to drink (good wine and cocktails) and enjoy the party.
Public - a week ago
reviewed a week ago
Nice place for a drink outside in the summer. The prices are a little higher than elsewhere, but then make up for it with the atmosphere.
Public - a month ago
reviewed a month ago
680 reviews
Map
Map
Map
Small but nice bar with an amazing view of the old town and the lake.
Public - a week ago
reviewed a week ago
Lovely buffet and friendly service.
Public - 3 weeks ago
reviewed 3 weeks ago
Delicious Neapolitan style pizza! I've been to Naples and can confirm that this is the authentic style of pizza. The pizza from Naples is less crisp than most expect, with a more soft and spongy dough. We had a great evening here, sitting outdoor in the warm weather.
Public - a month ago
reviewed a month ago