Skip to content

Commit

Permalink
Blog post
Browse files Browse the repository at this point in the history
  • Loading branch information
sindresorhus committed Aug 14, 2024
1 parent 9941793 commit 7eb3a8a
Show file tree
Hide file tree
Showing 6 changed files with 54 additions and 28 deletions.
23 changes: 10 additions & 13 deletions source/content/apps/dato.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,6 @@ olderMacOSVersions:
- '11'
- '12'
- '13'
feedbackNote: |
**Dato 5.3.1 triggered a bug in macOS which caused Dato to crash for some users. I submitted an update with a fix immediately, but it took Apple almost 1 week to approve it. The update is finally out now. Look for Dato 5.3.3 or later on the App Store. I'm really sorry for the inconvenience.**
**If you previously downloaded a temporary version from here, make sure you delete it before getting the App Store version again.**
---

### Dato not launching

**Dato 5.3.1 triggered a bug in macOS which caused Dato to crash for some users. I submitted an update with a fix immediately, but it took Apple almost 1 week to approve it. The update is finally out now. Look for Dato 5.3.3 or later on the App Store. I'm really sorry for the inconvenience.**

**If you previously downloaded a temporary version from here, make sure you delete it before getting the App Store version again.**

---

Dato gives you a local clock, date, and multiple world clocks in the menu bar. When you click Dato in the menu bar, you get a menu with a calendar, calendar events, and world clocks. All of this is highly customizable.
Expand Down Expand Up @@ -275,7 +263,16 @@ No. Dato is only available from the App Store and Setapp.

#### The “upcoming event in menu bar” notification is not showing up

Make sure you have enabled the feature in the settings and enabled the correct calendars for it (it has a separate calendar picker). Also make sure that there is enough space in the menu bar to show it. If you have Bartender (or a similar app that hides menu bar items) installed, make sure the menu bar item was not auto-hidden by Bartender. Note that it uses a separate menu item from the main Dato menu item.
Make sure:

- The feature in enabled in the settings.
- The correct calendars for it are enabled (it has a separate calendar picker).
- When in the settings for it, the placeholder example menu bar item shows up in the menu bar.
- If it doesn't show up, try reducing the “event title limit”.
- There is enough space in the menu bar to show it.
- If you have Bartender or Ice (or a similar app that hides menu bar items) installed, make sure the menu bar item was not auto-hidden by Bartender.
- Note that it uses a separate menu item from the main Dato menu item, so it could still be hidden by Bartender while the main menu bar item is not.
- Try quitting Bartender to make sure it is not one causing the issue.

#### It does not support the video call service I use

Expand Down
1 change: 1 addition & 0 deletions source/content/blog/dato-setapp.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
---
unlisted: true
title: Dato + Setapp = ❤️
description: My Dato app is now available on Setapp.
pubDate: 2023-03-17
Expand Down
41 changes: 41 additions & 0 deletions source/content/blog/micro-benchmark-fallacy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
---
title: The Micro-Benchmark Fallacy
description: It's a trap.
pubDate: 2024-08-13
tags:
- programming
---

Micro-benchmarks, while seemingly insightful, often mislead developers by presenting a skewed view of performance. They isolate small fragments of code, amplifying their significance in ways that don’t reflect real-world scenarios.

### Lack of Real-World Context

Micro-benchmarks strip away the complexities of actual apps. A function may perform well in isolation, but its impact on overall system performance can be negligible.

### Artificial Testing Conditions

These benchmarks typically run under ideal circumstances, failing to account for real-world factors like I/O operations, network latency, and user interactions that significantly affect performance.

### Misguided Optimization Focus

Obsessing over micro-optimizations often yields diminishing returns. It's more productive to focus on optimizing critical paths and bottlenecks that genuinely impact user experience.

### Overlooking Concurrency and Parallelism

Apps generally rely heavily on concurrent and parallel execution. Micro-benchmarks typically test single-threaded performance, which may not accurately represent how code behaves in a multi-threaded environment.

### Neglecting Startup and Initialization Costs

Some operations have significant startup or initialization costs that are amortized over time in long-running apps. Micro-benchmarks may overemphasize these costs if they don't run long enough, leading to misguided optimization efforts.

### JIT and Caching Complications

Modern languages use Just-In-Time (JIT) compilation and caching to dynamically optimize performance. Micro-benchmarks include warm-up phases to account for this, but often miss the full impact. A function in a micro-benchmark might run faster or slower when integrated with other code due to changes in execution paths, resource contention, or different inlining decisions.

### Misleading Marketing

Be skeptical of projects that boast micro-benchmark results. These figures are often cherry-picked and rarely reflect real-world performance. A prime example is when frameworks use these benchmarks to promote their performance, showcasing isolated scenarios where they shine. However, these results quickly lose relevance once real-world factors like database I/O come into play. Such benchmarks often distract from more important considerations when evaluating a framework.

### The Bottom Line

While micro-benchmarks can provide some insights, they shouldn't be the primary basis for performance optimization decisions. Instead, focus on comprehensive profiling of your app under realistic conditions to identify and address genuine performance bottlenecks.
7 changes: 0 additions & 7 deletions source/content/blog/new-blog.md

This file was deleted.

8 changes: 0 additions & 8 deletions source/content/blog/shell-free-scripts.md

This file was deleted.

2 changes: 2 additions & 0 deletions source/content/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@ const blogCollection = defineCollection({
description: z.string().nonempty().optional(),
pubDate: z.date(),
tags: z.array(z.enum([
'programming',
'open-source',
'swift',
'javascript',
'nodejs',
])).optional(),
Expand Down

0 comments on commit 7eb3a8a

Please sign in to comment.