<Regenaxer>
How does it find out uninitialized memory? By pre-filling with some pattern?
<Regenaxer>
No idea why it complains
<tankf33der>
sanitizer counts memory access.
<tankf33der>
if checked then ok.
<Regenaxer>
checked in which way?
orivej has quit [Ping timeout: 256 seconds]
<beneroth>
hi Regenaxer, tankf33der
<beneroth>
Regenaxer, for every memory read, check if it was written before, if not == uninitialized memory access
<beneroth>
if that is the topic...
<Regenaxer>
Hi beneroth
<Regenaxer>
it checks by pre-filling?
<Regenaxer>
Or how else?
<beneroth>
I don't know the method here in question
<Regenaxer>
It cannot track every memory access without hardware support
<beneroth>
but prefilling, or with active profiling like pil's (trace), decorate every memory access call
<Regenaxer>
and obviously the memory is correct here
<Regenaxer>
the contents
<beneroth>
can't it, if its goes basically MitM between the software and the hardware?
<beneroth>
hm ok
<Regenaxer>
to trace it that way, it must track machine instructions
<Regenaxer>
ie hardware
<Regenaxer>
perhaps CPUs support that
<Regenaxer>
debug instructions
<Regenaxer>
probably only by super user
<Regenaxer>
anyway
<Regenaxer>
I'd like to know why it believes it is uninitialized. Perhaps it is. But which memory?
<Regenaxer>
Not very helpful
<beneroth>
yeah which memory is the question
<Regenaxer>
If it really detects it, it should better tell exactly *which* range of memory
<Regenaxer>
T
<Regenaxer>
Above we write() 159 byte
<Regenaxer>
the number has 158
<Regenaxer>
I assume the last byte is a newline
<Regenaxer>
So everything looks good
rob_w has quit [Ping timeout: 272 seconds]
rob_w has joined #picolisp
mtsd has quit [Quit: Leaving]
orivej has joined #picolisp
rob_w has quit [Remote host closed the connection]
orivej has quit [Ping timeout: 258 seconds]
orivej has joined #picolisp
<dexen>
perhaps could use the paging mechanism for tracking all memory accesses?
<dexen>
rough idea: allocate a protected (no read, no write) memory region. adjust all *relevant* pointers by adding a large constant, to make them all point to the protected memory region.
<dexen>
any attempt at accessing the pointer will cause SIGSEGV, catch it, subtract the large constant from the pointer to obtain the *actual* / original value