HNHacker News
TopNewBestAskShowJobs

sirn

3,953 karma · joined October 25, 2009

Contact: sirn@ogsite.net

Software developer living in Tokyo, Japan

Previous: Oozou (BKK), Omise (BKK→TYO), Varnish Software (TYO), EnergyRoute Japan (TYO)

I run a small IT consulting business in Japan; feel free to email.

submissionscomments
sirn··on M1 Macs cannot support dual Extended displays through their Thunderbolt 3 ports
This is mostly because Thunderbolt hub support was optional in Thunderbolt 3 spec, but mandatory in USB 4. Apple just added support for it in Big Sur.
sirn··on M1 Macs cannot support dual Extended displays through their Thunderbolt 3 ports
There's a recently announced OWC Thunderbolt Hub[1]. I would still prefer to have 4 ports built-in even with two controllers rather than having to deal with hubs, though.

[1]: https://eshop.macsales.com/shop/owc-thunderbolt-hub

sirn··on M1 Macs cannot support dual Extended displays through their Thunderbolt 3 ports
I'm using the standard scaled 1920x1080 resolution on both of my screens. I don't see the 3008x1692 option on my 27-inch LG 4K, but I do see the option on 16-inch Wacom Cintiq. It's a little bit too small on my 16-inch, though.
sirn··on M1 Macs cannot support dual Extended displays through their Thunderbolt 3 ports
I've been running this setup. Mac mini M1 connecting to LG 4K monitor over HDMI at 60 Hz, with DisplayPort to a 4K Wacom Cintiq also at 60 Hz. It works flawlessly.
sirn··on M1 Macs cannot support dual Extended displays through their Thunderbolt 3 ports
It might be worth noting that M1 Macs actually has two Thunderbolt controllers for 2 ports (dedicated controller for each port), whereas previous Macs shared two Thunderbolt controllers for 4 ports. The 2 ports limitation feels to me like a design decision rather than a hardware limitation (to differentiate with an upcoming higher-end model?)
sirn··on Payment processor for Amazon India had leak of over 100M users
Unfortunately, credit card security for traditional online payment rely on payment processor actively blocking bruteforce attempts and CVC number never being stored to stay secure.

Masking six digits out of sixteen digits is a very common practice in the industry. The first 6 is BIN which is sort-of public data (full BIN table are distributed by Visa/Master only to acquirer/issuer, but some acquirer may provide them for free to a payment processor/merchant), next 6 is not unique enough since it depends on issuer's scheme so last 4 is used for identifying a card with the middle 6 masked.

I don't know about this particular case (and it depends on QSA), but if the number is in any way reversible e.g. a plain hash(card_number), it would put any system that store that hash in a PCI-DSS storage scope. I once worked with a system that solve this issue by having unique salt to each card, but the salt is never exposed outside of PCI-DSS scope. This prevent rainbow table attack, but still open to brute force.

3-D Secure was suppose provide a better security for online transactions by requiring a second factor (e.g. OTP), but it introduces a lot of hassle since it rely on HTTP POST from a client's browser (thus the "Your payment is being processed. Please do not refresh this page." screen), add two extra vendors to trust (ACS/MPI), and the card is still usable with merchants that doesn't enforce 3-D Secure (though I'm not sure if this is the case with India), making the whole scheme similar to having a tightly locked door with a window open wide. The scheme protects merchant more due to liability shift which removes them from being liable to chargebacks.

3-D Secure 2.0 tries to fix the hassle part by requiring merchant and payment processor to send data about the transaction back to the bank (email address, previous transaction info, shipping address, etc. which may be a privacy issue) and letting them decide whether a transaction should require an extra authentication.

sirn··on Ask HN: Has anyone purchased the base M1 Mac Mini for development work?
> Godot - doesn't work

Godot has been working well for me under Rosetta (though just a small 2D project using GDScript). Godot 3.2.3 actually supports Apple Silicon[1] although there's no binary build just yet. I've recently submit a patch to MacPorts to enable native Apple Silicon[2] and have been using it since without any issues (so far).

[1]: https://docs.godotengine.org/en/stable/development/compiling...

[2]: https://github.com/macports/macports-ports/pull/9552

sirn··on Google Maps' Moat Is Evaporating
It wasn’t that Apple removed Google Maps from App Store. Maps.app on iPhone were using Google Maps data prior to iOS 6. Google Maps the app didn’t existed when Apple switched to use Apple Maps.

Timeline:

Sep 19, 2012 - iOS 6

Dec 13, 2012 - Google Maps launched on App Store

sirn··on Raspberry Pi Server Mark III
My guess would be Nextcloud put a lot of load on both CPU and disk (for thumbnail generation, file encryption, etc.) making Raspberry Pi which lack performance in both front not very suitable for the task.

I tried running Nextcloud on Raspberry Pi 4 (4GB) a while ago, and hitting performance issue on SD card very fast (initial DB import take very long). I tried to solve this by moving all Nextcloud data into iSCSI disk but RAM & CPU became a problem once I started adding more files. After a week or so, I tore everything down and went back to a VPS instance.

It might works better with Raspberry Pi cluster on Kubernetes, though. (This very Raspberry Pi is now happily running as a DVB streaming server.)

sirn··on Facebook's Hypocrisy on Apple's New iOS 14 Privacy Feature
Many third party browsers actually implement their own networking bits. Firefox Mobile used to be based on Alamofire (but recently switched to NSURLSession). Chrome iOS uses the same stack as its desktop browser (Cronet). Third party browsers can implement adblocking any way they want, for example iCab 10 on iOS supports the AdBlock Plus format used by uBlock Origin.

Edit: most -> many

sirn··on Facebook's Hypocrisy on Apple's New iOS 14 Privacy Feature
I think the better way to put it is it is a real problem, but with a well known workaround. AFAIK, these slots needs to be pre-defined so you're still limited to number of lists that were defined at installation time.

This limitation prevent the model with traditional adblocker where extension and block lists are independently maintained by different parties (e.g. uBlock Origin/ABP + EasyList) so you're stuck with relying on extension maintainer to update their list or download another blocker app when the blocker become unmaintained (where in traditional model you could just subscribe to another list)

sirn··on Tech Preview of Docker Desktop for M1

       (5) Docker Image      (amd64)
                ^
                |
       (4) QEMU Binfmt       (arm64 <-> amd64 binary emulation layer)
                ^
                |
        (3) Linux VM         (arm64)
                ^
                |
   (2) Hypervisor.framework  (arm64, macOS native virtualization framework)
                ^
                |
      (1) Docker for Mac
Linux Kernel has a feature to allow using a wrapper to execute userspace program based on file header (binfmt[1]). In this case, Linux VM in (3) has QEMU user mode emulation registered as binfmt, so any amd64 binaries are automatically wrapped into `qemu-x86_64-static /path/to/bin` and run. Docker Image itself doesn't run a Linux kernel but use one from the VM host, so this scenario is possible.

This is also how multiarch[2] works (for amd64 to arm64/ppc64le/etc.) which might even be what Docker is using. In case of multiarch, the qemu-*-static binary is provided as a container running in privileged mode.

[1]: https://www.kernel.org/doc/html/latest/admin-guide/binfmt-mi...

[2]: https://github.com/multiarch/qemu-user-static

sirn··on CD Projekt Conference Call with the Management Board [pdf] (Dec 14)
The camera one is easy to fix and I found it to be a fair mechanic. However the bug here is even all camera is disabled (either via a daemon, turning them off individually, or shooting them down, or even in area with no cameras, e.g. Nash part in Ghost Town quest) they can Overheat you from behind a solid wall or even in a different room.

My guess is this is similar to enemy sniper sometimes can see you through walls. If they're close enough to a wall, then their line of sight is calculated as if they were in front of a wall.

sirn··on CD Projekt Conference Call with the Management Board [pdf] (Dec 14)
I Spy only solve half the problem with Overheat. Enemy nethackers can Overheat you behind a cover, and moving out of line of sight doesn't stop Overheat from uploading.
sirn··on CD Projekt Conference Call with the Management Board [pdf] (Dec 14)
It has been working well for me as well (on a PC). I love the story and the visual. However the combat system is simply broken. Police spawns out of nowhere when a crime is reported[1]. Really bad reticle drifting behavior[2]. Enemy sniper can 1-hit kill you even when they are far away enough for the game to not render them. Enemy spamming Overheat from behind a wall (even with all cameras disabled, which is game-breaking on Very Hard), and much, much more.

I wasn't even looking for them, but they managed to find me. I still enjoy the game a lot, but combat has been nothing but frustration.

[1]: https://www.polygon.com/2020/12/10/22167436/cyberpunk-2077-w...

[2]: https://www.reddit.com/r/cyberpunkgame/comments/kbwpps/retic...

sirn··on AirPods Max
It lets everyone hears but the sound is not that loud, e.g. manageable even in a room with bad sound insulation. Beside, a comparable speaker setup in term of sound quality takes a lot of space and cost a lot more which may not be desirable.
sirn··on AirPods Max
I have $4,000 audio setup (Sennheiser HDV820 + Sennheiser HD800) and honestly a $500 Sennheiser HD650 plugged directly to a 3.5mm adapter sounds way more fun in everyday use. The exponential quality curve only goes up to certain point and beyond that it's all about the sound characteristic (HD800/S is good for classical/jazz) and how much the manufacturer is going charge for it.

That being said, I still use AirPods Pro a lot more than both HD800 and HD650 due to convenience of using it even though the sound quality is way worse. Fidelity isn't really much of a concern when I'm doing something else with background music.

I'm very excited about AirPods Max.

sirn··on Apple’s “Extended Dynamic Range” Brings HDR to Non-HDR Displays
Very fascinating! I wondered about this and went to search around a bit, and found this bit[1] (though this is more about CRT TV)

> When we used to manufacture TVs, we'd produce them for customers in the southern hemisphere too. When building these, we had to run them through our production lines upside down.

> When the old cathode ray tube TVs were built, the earth's magnetic field was taken into account during the production process. This ensured the current flowed the right way through the TV and so the TV was able to function normally.

[1]: https://twitter.com/SonyUKTEC/status/1228239522166501376

sirn··on Apple’s “Extended Dynamic Range” Brings HDR to Non-HDR Displays
The main issue with comparing the spec is the difference are not really shown in these specs, e.g. luminance and chromaticity uniformity (aka Delta E), among other things. Consumer grade monitor usually do not have these, and when combining with wide color gamut and _measured_ color space (not claimed), we're talking about at least higher grade EIZO monitors which are not less than $1k.

The monitor that are comparable to the Pro XDR Display are ASUS PA32UCX ($4500) or EIZO CG319X ($6000) which usually requires full recalibration every certain amount of usage.

sirn··on Apple CPU tricks: memory reordering, JavaScript support, ref counting
Isn't the extra 2 on Zen not a decoder unit, but rather a 6-way dispatch[1] with op-cache being used to kept the execution unit busy? Or was that the reason behind calling it a 5 or 6-wide depending on how one's may count it considering cache miss and all?

[1]: https://images.anandtech.com/doci/16214/Zen3_arch_5.jpg

sirn··on Apple Silicon M1: Black Magic Fuckery
I also believe this is the case.

Most experiment with 8GB M1 Macs I've seen so far (on YouTube) seems to start slowing down once the data cannot fit in a RAM, although the rest of the system remain responsive e.g. 8K RED RAW editing test. In the same test with 4K RED RAW there were some shuttering on the first playback but subsequent playback were smooth, which I guessed it was a result of swap being moved back into a RAM.

My guess would be they've done a lot of optimization on swap, making swapping less of an performance penalty (as ridiculous as it sounds, I guess they could even use Neural Engine to determine what should be put back into RAM at any given moment to maximize responsiveness.)

macOS has been doing memory compression since Mavericks using WKdm algorithm, but they also support Hybrid Mode[1] on ARM/ARM64 using both WKdm and a variant of LZ4 for quite some time (WKdm compress much faster than LZ4). I wouldn't be too surprised if M1 has some optimization for LZ4. So far I haven't seen anybody tested it.

It might be interesting to test M1 Macs with vm_compressor=2 (compression with no swap) or vm_compressor=8 (no compression, no swap)[2] and see how it runs. I'm not sure if there's a way to change bootargs on M1 Macs, though.

[1]: https://github.com/apple/darwin-xnu/blob/a449c6a3b8014d9406c...

[2]: https://github.com/apple/darwin-xnu/blob/a449c6a3b8014d9406c...

sirn··on Why Japanese web design is so different (2013)
Not really a tool per-se, Japanese has standardized subset of kanji suitable for computer use. This is the JIS X 0208 (Kanji 1 and Kanji 2 containing 6,879 characters) and JIS X 0213 (Kanji 3 and Kanji 4 containing 11,233 characters). There are several tricks font designer can utilizes, such as reusing radicals (component of a kanji) and combine them. This technique only works for certain type of fonts and still requires hand-tuning.
sirn··on 1MB Club
I don't think this chart really tell much because most services are hosted in the US which some of these country have small or no direct link to (e.g. Thailand is 6th fastest in APAC on average speed, but the whole country has total of 30Gbps direct link to the US and pretty much have to route everything via HK or SG) which sometimes result in horrendous latency (~500ms) or speed (< 1 Mbps). It's fast at CDN edge where these surveys are taken, but page sizes still matter a lot.
sirn··on Show HN: Zfs.rent
rsync.net also offers block-level replication via zfs send[1]

[1]: https://www.rsync.net/products/zfsintro.html

sirn··on AMD Radeon RX 6800 and RX 6800 XT Review
FWIW, the thing about HiDPI being blurry is partly design difference between X11 and Wayland, and partly design decision on sway part (to not support this scenario). Having X11 and Wayland applications in HiDPI means having to handle two DPI in a single screen (e.g. sway have to render Xwayland window at 1x, while other windows at 2x).

This can be quite tricky since Xwayland's DPI may not always equal to `display DPI * Wayland scale` and while DPI settings in X is global, scale settings in Wayland is per-output. GNOME for instance has HiDPI working for both Xwayland and Wayland windows but with lots of magic going on with the framebuffer. HiDPI for X window in Plasma is still in the works AFAIK.

(This is a blocker for me as well.)

sirn··on AMD Radeon RX 6800 and RX 6800 XT Review
Right now it's reported by Linus Tech Tips[1], but I don't think I've seen anyone in the /r/VFIO community tried it yet (partly due to availability). I'm very curious about this as well and might as well get one and try it myself...

[1]: https://youtu.be/oUzCn-ITJ_o?t=642

sirn··on AMD Radeon RX 6800 and RX 6800 XT Review
AFAIK, RX 580 is the only exception for anything newer than Hawaii that doesn't have the reset bug (and only from certain vendor, Sapphire RX 580 I believe).
sirn··on AMD Radeon RX 6800 and RX 6800 XT Review
In addition to all these numbers, AMD also finally fixed the GPU reset bug with 6800 cards[1], which is huge for those of us running GPU passthrough to a VM as a BACO workaround kernel patch is no longer needed. Possibly going to be more stable on Linux as well as the card can recover itself from crashes. Big Navi also has its driver upstreamed in current 5.9 kernel so no more first day disaster like Navi.

(Meanwhile Nvidia also removed the "error 43" limitation when it detected the card is being run in a VM, so VFIO scene is getting a lot more interesting in this generation.)

[1]: https://www.youtube.com/watch?v=ykiU49gTNak

sirn··on Factorio 1.1 is getting close
> You don't have to spend hours reading documentation to find the function you want, or googling for stack overflow answers for some build error

...until you start messing with fluid system and oil cracking

sirn··on Apple Silicon M1 chip in MacBook Air outperforms high-end 16-inch MacBook Pro
Anandtech has done SPECint on A14 and result is consistent with what we've seen from M1 on Geekbench. It's not the same CPU, but they share the same Firestorm/Icestorm cores.

https://www.anandtech.com/show/16226/apple-silicon-m1-a14-de...

← PreviousPage 6 of 29Next →