Ghosts in the machine
Mar. 8th, 2010 05:47 pmI work in embedded systems for my Master's thesis. The particular one I use is a fairly cutting-edge one called an X-Core. It's really new and is pretty fun to use. I think it represents the future in manycore processor design.
I've been struggling to get some low-level hacking going. Minimal documentation, unclear information, you name it, I'm dealing with it. Things are starting to come together. Code compiles, uploads, and executes.
But there's a ghost. It's weirding me out. I've used/programmed computers since 1995 or so. One of the key principles of programming computers is this:
In my code, not only is B executing before A, it's doing it some number of times, and then it's doing it out of order (I have a counter ticking upwards every time B runs).
There is no reason for B to execute even once before A, and there's even worse reason for B to execute out of order.
This is actually kinda freaky.
I've been struggling to get some low-level hacking going. Minimal documentation, unclear information, you name it, I'm dealing with it. Things are starting to come together. Code compiles, uploads, and executes.
But there's a ghost. It's weirding me out. I've used/programmed computers since 1995 or so. One of the key principles of programming computers is this:
- When two statements A and B are sequentially ordered; e.g., A; B;, then A shall always execute before B.
In my code, not only is B executing before A, it's doing it some number of times, and then it's doing it out of order (I have a counter ticking upwards every time B runs).
There is no reason for B to execute even once before A, and there's even worse reason for B to execute out of order.
This is actually kinda freaky.
no subject
Date: 2010-03-09 05:28 am (UTC)no subject
Date: 2010-03-09 08:52 pm (UTC)...that setting the JTAG debug interrupt to a custom handler SOMEHOW triggers the debug interrupt some variant number of times on software load. (But a hard reset fixes the matter).