cast1.c
up: index
prev: cast0.c
next: revoke1.c
#include <inttypes.h>
#include "capprint.h"
int main()
{
int x=42;
int *p = &x;
fprintf(stderr,"Original: %" PTR_FMT "\n", sptr((void*)p));
intptr_t c = (intptr_t)p;
fprintf(stderr,"Casted: %" PTR_FMT "\n", sptr((void*)c));
}
Experimental data (what does this mean?)
cerberus-cheri-no-pnvi
cerberus-cheri-revocation-no-pnvi
cerberus-cheri-cornucopia-no-pnvi Original: (@disabled, 0xffffe710 [rwRW,0xffffe710-0xffffe714])
Casted: (@disabled, 0xffffe710 [rwRW,0xffffe710-0xffffe714])
cerberus-cheri
cerberus-cheri-revocation
cerberus-cheri-cornucopia Original: (@81, 0xffffe710 [rwRW,0xffffe710-0xffffe714])
Casted: (@81, 0xffffe710 [rwRW,0xffffe710-0xffffe714])
clang-riscv-O3-bounds-subobject-safe Original: 0x3fffdfff2c [rwRW,0x3fffdfff2c-0x3fffdfff30]
Casted: 0x3fffdfff2c [rwRW,0x3fffdfff2c-0x3fffdfff30]
clang-riscv-O3-bounds-conservative Original: 0x3fffdfff3c [rwRW,0x3fffdfff3c-0x3fffdfff40]
Casted: 0x3fffdfff3c [rwRW,0x3fffdfff3c-0x3fffdfff40]
clang-riscv-O0-bounds-conservative
clang-riscv-O0-bounds-references-only
clang-riscv-O0-bounds-subobject-safe
clang-riscv-O0-bounds-aggressive
clang-riscv-O0-bounds-very-aggressive
clang-riscv-O0-bounds-everywhere-unsafe Original: 0x3fffdfff6c [rwRW,0x3fffdfff6c-0x3fffdfff70]
Casted: 0x3fffdfff6c [rwRW,0x3fffdfff6c-0x3fffdfff70]
clang-morello-O3-bounds-subobject-safe Original: 0xfffffff7fefc [rwRW,0xfffffff7fefc-0xfffffff7ff00]
Casted: 0xfffffff7fefc [rwRW,0xfffffff7fefc-0xfffffff7ff00]
clang-morello-O3-bounds-conservative Original: 0xfffffff7ff2c [rwRW,0xfffffff7ff2c-0xfffffff7ff30]
Casted: 0xfffffff7ff2c [rwRW,0xfffffff7ff2c-0xfffffff7ff30]
clang-morello-O0-bounds-conservative
clang-morello-O0-bounds-references-only
clang-morello-O0-bounds-subobject-safe
clang-morello-O0-bounds-aggressive
clang-morello-O0-bounds-very-aggressive
clang-morello-O0-bounds-everywhere-unsafe Original: 0xfffffff7ff5c [rwRW,0xfffffff7ff5c-0xfffffff7ff60]
Casted: 0xfffffff7ff5c [rwRW,0xfffffff7ff5c-0xfffffff7ff60]
gcc-morello-O3 Original: 0x7fffffdc [rwRW,0x7fffffdc-0x7fffffe0]
Casted: 0x7fffffdc [rwRW,0x7fffffdc-0x7fffffe0]
gcc-morello-O0 Original: 0x7fffffbc [rwRW,0x7fffffbc-0x7fffffc0]
Casted: 0x7fffffbc [rwRW,0x7fffffbc-0x7fffffc0]