Chapel St. Laurentius Wylen

Image

During the night we received the first snow for this winter. The sun was breaking through the clouds in the afternoon, and it happened that I was near Brunnen to take of the Wylen chapel with the snow-covered Mythen in the background:

Kapelle Wylen

Kapelle Wylen

Continue reading

Advertisements

GNU gcc printf() and BuiltIn Optimizations

Readers of my blog know: I’m not a fan of printf(), and I think for many good reasons. Still printf() is widely used, and the GNU gcc tries to optimize things. This is observed with a simple example: If I’m writing

printf("a");

Then the code produced (ARM Cortex-M0+ with GNU ARM Embedded 4.9 2015q2 gives:

movs r0, #97    ; 0x61
bl 0xa98

Instead of calling printf(), it is calling putchar()! Why is that?

PutChar instead of Printf

PutChar instead of Printf

Continue reading