On 25 June 2017 at 22:51, Theodore Dubois <tbl...@icloud.com> wrote: > In include/exec/cpu_ldst_useronly_template.h, there’s > references to glue(glue(ld, USUFFIX), _p), which would > expand to a call to a function looking something like > uint32_t lduw_p(void *) (for example). Where is this > function defined?
lduw_p is a #define in include/exec/cpu-all.h: it expands to either lduw_be_p or lduw_le_p depending on whether the target CPU is big or little endian. lduw_le_p/lduw_be_p are defined as inline functions in include/qemu/bswap.h (and are in turn implemented using other functions and macros also defined in bswap.h). thanks -- PMM