Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
likelynew
· 9y ago · 0 comments
Why is it so slow(compared to the post) in the macbook air. Native yes runs at 26 MiB/s, and GNU yes at 620 MiB/s.
Comments
[–]
aselzer
9y ago
It isn't! yes runs at 7.2 GiB/s on my macbook air. Though I have Linux installed on it instead of Mac OS :)
[–]
School-Cotton
9y ago
Are you trolling? The commenter obviously meant the macOS version of "yes".
[–]
masklinn
9y ago
The VM subsystem is much slower. Also possibly a not-up-to-date GNU grep, on my (ancient) MBP I get 26MB "native", 780MB GNU and 2.8GB for TFA's C program (2.9 if I replace the malloc by a stack-allocated array, weirdly enough)
[–]
tomsmeding
9y ago
Probably alignment issues: stuff on the stack might be aligned by default, in contrast to malloc'd memory.
[–]
AstralStorm
9y ago
The CPU and RAM are slower and there is much more kernel overhead. Not to mention pipe buffer size is small on OS X.
[–]
AstralStorm
9y ago
Come on people, I ran GNU yes just there, it isn't as slow as OP says but it is a quarter of expected performance.