CTSRD-CHERI/llvm-project

CheriBoundAllocas should also consider permissions

jrtc27 opened this issue · 0 comments

void foo(void *);

void
bar(void)
{
    const int x = 42;

    foo((void *)&x);
}

Ideally foo would have a read-only capability since the underlying object is const.

https://cheri-compiler-explorer.cl.cam.ac.uk/z/6qhjW6