4 ms·
Not to mention that a big part of the confusion is not even the compilation - it's not beyond possibilities to inspect the machine code - but the processor itse
by sharikone 5y ago
Not to mention that a big part of the confusion is not even the compilation - it's not beyond possibilities to inspect the machine code - but the processor itself still does a lot of unintuitive stuff, even more so with concurrency. I wish the tooling you mention existed, but also some microcode simulation/implementation to look beyond that.
- kaba0 5y agoI’m not sure what are you thinking of, but CPUs are guaranteed to run as if the given instructions were executed one after another, even though in practice it is free to reorder them slightly.
- astrange 5y agoMemory operations aren't required to behave like that, although on x86 they mostly do. ARM and Alpha certainly don't.
- chrisseaton 5y ago> CPUs are guaranteed to run as if the given instructions were executed one after another That’s just not true. Intel models will reorder reads and other processors will even reorder writes - and I’m talking about observably.
- bregma 5y agoI've dealt with many CPUs designed to run out of sequence and to guarantee that. I've dealt with multiprocessor computers where order is not guaranteed at all outside the use of hardware interlinks. I've dealt with embarrassingly parallel processors where instruction order is orthogonal. Perhaps you're thinking of a simple abstract CPUs used in "introduction to computers" courses instead of the real-life silicon used in most applications?