News for hackers. Stuff that matters.
Re:AT&T Syntax versus Intel Syntax by googlryas on Sunday November 13, 2022 @02:45PM (#33586601)
That is just an arbitrary notation, nothing to do with logic. In English at least, "add 4 to x" is more natural than "add to x 4".

Ergo op src dest

Re:AT&T Syntax versus Intel Syntax by bialpio on Sunday November 13, 2022 @03:08PM (#33586794)
But English "add 4 to x" tells you nothing about where to store the result. : - )

"Add 4 to x and store result in x" vs "Let x be x + 4"?

Re:AT&T Syntax versus Intel Syntax by monocasa on Sunday November 13, 2022 @03:17PM (#33586892)
Without any other context, you generally assume that the target is an accumulator.

So "add 4 coins to that bucket", generally means at the end of that operation the bucket contains at least four coins plus any coins that were already in the bucket.

Re:AT&T Syntax versus Intel Syntax by bialpio on Sunday November 13, 2022 @05:26PM (#33588039)
Huh, I think my brain is not wired to think about `x` as a storage, it is closer to "add 3 to x for x = 2", which then gets reduced to "add 3 to 2" and then the destination is missing...