Hi Shawn,
I am glad that you found these sanitizers useful. Presently, Ubsan is available in ramstage on all platforms whereas ASan is only available on x86 platforms. You can refer to
this page to learn more about ASan in coreboot.
Regarding the type mismatch in
memory_is_poisoned_16(), I don't see any problem with the current implementation. Dereferencing shadow_addr returns either 0 or unsigned chars FA, F1, F2, etc depending upon the type of memory bug found. However, if we just want to silence Ubsan here, I think we change it to something like return *shadow_addr != 0 ? true : false. I would like to hear others' opinions on this.
Best,
Harshit