Broken generic implementation of atomic

  • Natacha

    Natacha - 2009-05-25


    yesterday I got a brand new MIPSel-based netbook, and while the CPU is probably far from being powerful enough to make it a decent rendering platform, I tried to compile Pixie 2.2.6 out of curiosity. It failed to compile src/ri/atomic.h

    This atomic.h seems to be designed to assemble atomic increment and decrement on known platforms, and to fallback on generic C++ code on unkown platform. That MIPSel netbook seems to be an unkown platform.

    The problem with that generic C++ code is that it relies on the CRenderer class, and osLock() and osUnlock() functions, which are not declared anywhere in atomic.h. I tried the obvious fix of #including "renderer.h" right after the #warning line (line 144 of Pixie 2.2.6), but for some strange reason I still had the same "undeclared stuff" errors.

    I will investigate it more thoroughly when I have more time, but I still report it in case somebody can have a look at it sooner than me (you can probably mess up with the #if to compile the generic code even on a known platform, something is obviously wrong, only the fix doesn't seem obvious).

    Hoping it helps,

  • Alex

    Alex - 2010-05-21

    What operating system are you running?


Log in to post a comment.