1,119 karma · joined Jan 8, 2014 (12y ago) · 185 submissions
comment 1w ago · link · parent
The text says that the 616A uses the two diodes that are unused in the 680A but your hypothesized metal layer for the 616A shows those diodes as being unused. They are shown as being used in the hypothesized metal layer for the 670A though. The 670A and the 680A both need 12 diodes and the 616A only needs 10, if I counted correctly. And yet there are 14 total diodes on the die so none of these three models needs all of them. Maybe it was easier to route the signals this way?
comment 3mo ago · link · parent
comment 4mo ago · link · parent
> compilers will never auto-vectorize loops with an early loop break afaik.
I think this is changing. https://godbolt.org/z/ea1E7dx9v. GCC 14 won't try to vectorize this because of the break statement. But GCC 15 does vectorize it. This got a callout in the "General Improvements" section of the release notes: https://gcc.gnu.org/gcc-15/changes.html
I don't think there's any equivalent in clang/LLVM.
comment 4mo ago · link · parent
comment 4mo ago · link · parent
comment 5mo ago · link · parent
If they had extra pins that they had no use for, I'm sure this would have seemed like a very easy and cheap addition. You take 4 unused pins and add 4 pulldown resistors. Then when you go to draw the background, instead of using index 0, you take the value for the index from those pins.
Maybe they planned to use this in arcade hardware, where you'd have a bigger budget than a home console and could afford two PPUs. Then you'd get more colors, and you could scroll the background layer independently from the foreground layer. I believe they later added support for independent layers on the SNES hardware so this type of thing was probably already in demand from game designers.
comment 5mo ago · link · parent
comment 9mo ago · link · parent
In Figure 3 you somehow have 101% wall time. :)
comment 9mo ago · link · parent
GCC trunk seems to like using `bool` so we may eventually be able to retire the hack of using `int`.
comment 9mo ago · link · parent
Though not the same thing, you may be interested in https://en.wikipedia.org/wiki/Laser_Interferometer_Space_Ant...
comment 10mo ago · link · parent
Or you could install and old copy of Cygwin or MinGW.
Do you want to run a modern Visual Studio and target XP? Maybe you can make that work if you install an old platform SDK and set WINVER and _WIN32_VERSION and work around all the warnings and compatibility problems that you'll run into. It is fighting an uphill battle and it will continue to get worse with each new version of VS that you want use.
For rust there is Rust9x https://seri.tools/blog/announcing-rust9x/. But I think this is the effort of handful of people. It is behind the upstream rust and it could go away at any time. If you want to write a toy program in Rust then it is fine, but if you want something that's going to be supported long-term you're rolling the dice.
Python 3.4.4 is the last version of Python that will run on Windows XP. That's 10 years old and many things on PyPI now require newer versions of Python so you'd be stuck with old, unsupported versions of those modules, possibly containing security issues.
comment 11mo ago · link · parent
comment 11mo ago · link · parent
comment 11mo ago · link · parent
I feel like it is unfair to blame the compiler when you've explicitly asked for `/O1`. If you change this to `/O2` or `/Ox` then MSVC will optimize this into a constant 5, proving that it does "know" that strlen will return 5 in this case.
comment 11mo ago · link · parent
Interestingly, it is comparing against a different 32-bit value than `bar` does. I think this is because you accidentally got the order backwards in `bar`.
The code in `bar` is probably not a good idea on targets that don't like unaligned loads.
comment 1y ago · link · parent
comment 1y ago · link · parent
I'm using x86_64-15.1.0-release-win32-seh-msvcrt-rt_v12-rev0.7z from https://github.com/niXman/mingw-builds-binaries/releases/tag... as the toolchain. This produces a 102 KB .exe file. Right off the bat we are doing much better than the claimed 278 KB. Maybe the author is using a different toolchain or different settings? Exact steps to reproduce would be welcome.
We can improve this by passing some switches to GCC.
gcc -Os => 100 KB
gcc -Oz => 99 KB
gcc -flto => 101 KB
gcc -s => 51 KB
gcc -s -Oz -flto => 47 KB
If all you are interested in is a small .exe size, there is plenty of room for improvement here.comment 1y ago · link · parent
23.
Probability Probably Doesn't Exist(scientificamerican.com ↗)
2 points · by abbeyj · 1y ago · discuss
25.
Major leap for nuclear clock paves way for ultraprecise timekeeping(nist.gov ↗)
12 points · by abbeyj · 1y ago · 10 comments
comment 2y ago · link · parent
comment 2y ago · link · parent
clang-tidy's `modernize-use-emplace` check warns for both the original version that uses `push_back` (as quoted in the article) and for the modified version that uses `emplace_back`:
warning: unnecessary temporary object created while calling emplace_back [modernize-use-emplace]
13 | widgets.emplace_back(Widget(foo, bar, baz));
| ^~~~~~~ ~
https://godbolt.org/z/sE7jWacTfIt appears that this check was improved to add this warning at some point between clang v14 and now. At least things have improved since the article was written.
comment 2y ago · link · parent