Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
albinofrenchy
· 9y ago · 0 comments
This isn't that conclusive of a test -- uninitialized memory is 0 relatively often.
Comments
[–]
clarry
9y ago
https://github.com/gcc-mirror/gcc/blob/4bec7283cda24b180ea7a...
[–]
pjscott
9y ago
Okay,
that
is conclusive. (And I'm pleasantly surprised by how readable GCC's source code is.)
[–]
kaushiks
9y ago
This has nothing to do with memory. The x86_64 ABI returns values from functions in the RAX register.
[–]
albinofrenchy
OP
9y ago
Sure; same point applies though -- just because 0 happens to be in RAX doesn't mean it's defined behavior.