static void listener_add_address_space(MemoryListener *listener,

                                       AddressSpace *as)

{

    FlatRange *fr;



    if (listener->address_space_filter

        && listener->address_space_filter != as->root) {

        return;

    }



    if (global_dirty_log) {

        listener->log_global_start(listener);

    }

    FOR_EACH_FLAT_RANGE(fr, &as->current_map) {

        MemoryRegionSection section = {

            .mr = fr->mr,

            .address_space = as->root,

            .offset_within_region = fr->offset_in_region,

            .size = int128_get64(fr->addr.size),

            .offset_within_address_space = int128_get64(fr->addr.start),

            .readonly = fr->readonly,

        };

        listener->region_add(listener, &section);

    }

}

static void listener_add_address_space(MemoryListener *listener,

                                       AddressSpace *as)

{

    FlatRange *fr;



    if (listener->address_space_filter

        && listener->address_space_filter != as->root) {

        return;

    }



    if (global_dirty_log) {

        listener->log_global_start(listener);

    }

    FOR_EACH_FLAT_RANGE(fr, &as->current_map) {

        MemoryRegionSection section = {

            .mr = fr->mr,

            .address_space = as->root,

            .offset_within_region = fr->offset_in_region,

            .size = int128_get64(fr->addr.size),

            .offset_within_address_space = int128_get64(fr->addr.start),

            .readonly = fr->readonly,

        };

        listener->region_add(listener, &section);

    }

}

    FOR_EACH_FLAT_RANGE(fr, &as->current_map) {     FOR_EACH_FLAT_RANGE(fr, &as->current_map) {     FOR_EACH_FLAT_RANGE(fr, &as->current_map) {
static void FUNC_0(MemoryListener *VAR_0,

                                       AddressSpace *VAR_1)

{

    FlatRange *fr;



    if (VAR_0->address_space_filter

        && VAR_0->address_space_filter != VAR_1->root) {

        return;

    }



    if (global_dirty_log) {

        VAR_0->log_global_start(VAR_0);

    }

    FOR_EACH_FLAT_RANGE(fr, &VAR_1->current_map) {

        MemoryRegionSection section = {

            .mr = fr->mr,

            .address_space = VAR_1->root,

            .offset_within_region = fr->offset_in_region,

            .size = int128_get64(fr->addr.size),

            .offset_within_address_space = int128_get64(fr->addr.start),

            .readonly = fr->readonly,

        };

        VAR_0->region_add(VAR_0, &section);

    }

}

static void FUNC_0(MemoryListener *VAR_0,
AddressSpace *VAR_1)
{ FlatRange *fr; if (VAR_0->address_space_filter
&& VAR_0->address_space_filter != VAR_1->root) { return; } if (global_dirty_log) { VAR_0->log_global_start(VAR_0); } FOR_EACH_FLAT_RANGE(fr, &VAR_1->current_map) { MemoryRegionSection section = { .mr = fr->mr,
.address_space = VAR_1->root,
.offset_within_region = fr->offset_in_region,
.size = int128_get64(fr->addr.size),
.offset_within_address_space = int128_get64(fr->addr.start),
.readonly = fr->readonly,
}; VAR_0->region_add(VAR_0, &section); } }