Re: Interview question?
On 2 Feb 2008 at 0:28, Flash Gordon wrote:
> Antoninus Twink wrote, On 01/02/08 21:20:
>> Here is a solution for Linux/gcc-i386. I had to make i volatile to stop
>> gcc optimizing it away.
>
> Doesn't work one all systems meeting that spec. For example, it does not
> work on this one.
>
>> #include <stdio.h>
>>
>> #define OFFSET 8 /* may need to change this depending on your compiler */
Did you change OFFSET appropriately for the version and optimization
level of your compiler, as specified in this comment?
|