I haven't considered David's proposal, however: On Wed, Mar 10, 2010 at 11:35:42PM +0900, Izumi Tsutsui wrote:
> - How much performance impact is expected for bus_space(9) changes > on ports that use macro for access functions? In the grand scheme of things, converting from macro to function proper doesn't matter since devices are not regular memory. Compared to cache or main memory, access to them is very slow. Also, I note that when we converted to functions on x86, the kernels dropped quite a bit in size. I think it was 200kB or so. The compiler was getting "clever" and generating massive code path duplication to handle the conditionals in the bus_space macros, with a minimal number of branches. In that instance, ignoring any percived benefit of inline function "calling" we had already shot ourselves in the foot by blowing all kinds of internal caches on the processor.