Skip to content

Some calls to Event::Event ctor require a very particular load sequence from .data section #70

Description

@robojumper

The ctor at 800a0c40 is sometimes called with a pattern like this:

// this works but I don't like it
static volatile u32 FLAGS_1 = 0x00000001;
static u32 FLAGS_2 = 0x00100001;
u32 f1 = FLAGS_1;
u32 f2 = FLAGS_2;
Event e = Event(mOffEventId, roomid, f2 & ~f1, nullptr, nullptr);
mEvent.scheduleEvent(e, 0);

Every call has its own copy of these statics even within the same file, and the volatile seems to be required to load them in the right order. This looks like an obvious hack but we haven't found a good way to match it...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions