Live data from Hacker News

Apple’s M1 processor and the full 128-bit integer product

lemire.me

131–140 of 180 posts

Re: Apple’s M1 processor and the full 128-bit integer product

#131
post #60

Earlier quoted context omitted.

The blog post links to the benchmark... It's repeatedly populating a 20k entry array with the results. godbolt clang compiles it to: .LBB5_2: // =>This Inner Loop Header: Depth=1 mul x13, x11, x10 umulh x14, x11, x10 eor x13, x14, x13 mul x14, x13, x12 umulh x13, x13, x12 eor x13, x13, x14 str x13, [x0, x8, lsl #3] add x8, x8, #2 // =2 cmp x8, x1 add x11, x11, x9 b.lo .LBB5_2 [1] https://github.com/lemire/Code-used-o…

I would be wary of using gettimeofday to measure such short periods. As https://pubs.opengroup.org/onlinepubs/009604599/functions/ge... says, the resolution of the system clock is unspecified, and 20,000 × ≈10 ≈ 200k instructions easily run in under a millisecond on modern hardware. The benchmark probably get rids of that by doing it 40,000 times in quick succession, but why not measure the time of all 40,000 iterati…

Agree, you probably want to just read some cpu time stamp counter before and after, and make sure you ar pinning your threwads, locking the clocks, etc. so that you can get a reliable time from there, or... just use cycles as your unit of measure.

Re: Apple’s M1 processor and the full 128-bit integer product

#132

Earlier quoted context omitted.

Nothing. Compute speed isn't that important if you're waiting on IO is GP's point.

In that case it's a confusing point, given GGP calls this nothingness "the real innovation of the M1". GP is asking what the innovation is.

It’s clearer if for M1 you read “the new architecture promoted by Apple around their M1 processor”.

Re: Apple’s M1 processor and the full 128-bit integer product

#133

I love my M1, but does anyone else have horrific performance when resuming from wake? It’s like it swaps everything to disk and takes a full minute to come back to life.

Yes. This is actually a known issue, provided you have an external monitor attached; lots of people complaining about it. The Mac actually wakes up instantly if you lift the screen, but it usually takes 5-10 seconds before it will wake up the external monitor. Worse, for some of us when it does finally wake up the monitor, sometimes it wakes it up with all the wrong colors, and rebooting is the only reliable fix. (an…

This happens to me too! Exactly as described. I have 16gbac mini conmected to an external monitor with an HDMI cable. A bit irritating but not a huge deal I don't do any color work on it so the occassional color issues are not a problem for me.

Re: Apple’s M1 processor and the full 128-bit integer product

#134

That's great if you App is compute bound. "May all your Processes be compute bound." Back in the real world most of the time your Process will be io bound. I think that's the real innovation of the M1 chip.

Explain please. What does the M1 do to IO loads?

On die memory and storage. No bottlenecks, very little latency.

Re: Apple’s M1 processor and the full 128-bit integer product

#135

Earlier quoted context omitted.

Yes. This is actually a known issue, provided you have an external monitor attached; lots of people complaining about it. The Mac actually wakes up instantly if you lift the screen, but it usually takes 5-10 seconds before it will wake up the external monitor. Worse, for some of us when it does finally wake up the monitor, sometimes it wakes it up with all the wrong colors, and rebooting is the only reliable fix. (an…

This happens to me too! Exactly as described. I have 16gbac mini conmected to an external monitor with an HDMI cable. A bit irritating but not a huge deal I don't do any color work on it so the occassional color issues are not a problem for me.

I've got an Intel Mini, and it's much faster to wake when I'm using a TB3->HDMI cable than an HDMI->HDMI cable. (Going to a dell 3219Q)

Re: Apple’s M1 processor and the full 128-bit integer product

#136
post #134

Earlier quoted context omitted.

Explain please. What does the M1 do to IO loads?

On die memory and storage. No bottlenecks, very little latency.

Important to clarify this every time it comes up: there is no on-die memory on the M1. It is normal, everyday, DDR4 memory which is located near to the processor. It's actually quite high latency at ~100ns.

Re: Apple’s M1 processor and the full 128-bit integer product

#137

Earlier quoted context omitted.

This happens to me too, I’m using 1Password. I have a suspicion the plug-in is involved with this but I’ve not had time to collect evidence yet. Seems to be rare though, I’ve not spotted anybody else with this issue.

Anecdotal but keeper and the built in keychain are instant ish at least not slow enough to notice

I don't use any external password manager, only Keychain and Safari and I see this 10-15 second delay every time when adding new password to Keychain since day 1.

It is my only issue with M1.

Re: Apple’s M1 processor and the full 128-bit integer product

#138
post #67
post #60

Earlier quoted context omitted.

The blog post links to the benchmark... It's repeatedly populating a 20k entry array with the results. godbolt clang compiles it to: .LBB5_2: // =>This Inner Loop Header: Depth=1 mul x13, x11, x10 umulh x14, x11, x10 eor x13, x14, x13 mul x14, x13, x12 umulh x13, x13, x12 eor x13, x13, x14 str x13, [x0, x8, lsl #3] add x8, x8, #2 // =2 cmp x8, x1 add x11, x11, x9 b.lo .LBB5_2 [1] https://github.com/lemire/Code-used-o…

Thanks for the link. Just staring at the machine code, it looks like the hottest loop for wyrng is about 10 instructions with a store in it. If the processor can do that loop in 1 cycle on average then...holy fuck. edit: I was looking at similar code generated by clang on my machine. Again, holy fuck. I don't think the story here is that 64x64=128 multiply is fast, honestly. The real story is the insane level of spec…

I don't think a large rob is a significant contributor here.

The very wide execution is though.

Re: Apple’s M1 processor and the full 128-bit integer product

#139

That's great if you App is compute bound. "May all your Processes be compute bound." Back in the real world most of the time your Process will be io bound. I think that's the real innovation of the M1 chip.

Exactly because of the "real world" argument, turns out that a lot of actual real world loads are CPU bounds because they are so wastefully implemented. IO of all kinds has extremely high bandwidth these days and OoO helps hide the latency.

Re: Apple’s M1 processor and the full 128-bit integer product

#140
post #134

Earlier quoted context omitted.

On die memory and storage. No bottlenecks, very little latency.

Important to clarify this every time it comes up: there is no on-die memory on the M1. It is normal, everyday, DDR4 memory which is located near to the processor. It's actually quite high latency at ~100ns.

Indeed and I was quite surprised by this as it's actually higher latency than you'd get on AMD or Intel's chips.
Post reply on HN