CUDApp
CUDA++: AIEN’s GPU machine-code toolchain, runtime and driver client for NVIDIA GPUs without the CUDA toolkit. Hardware coverage and driver replacement limits are explicit.
Brought by drakestapleton
CUDApp / om / standalone-oracles / red.c
| 1 | /* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception */ |
| 2 | /* Verification-only corruption at the strong Omega ABI. */ |
| 3 | #include <stdint.h> |
| 4 | #include <stdlib.h> |
| 5 | uint32_t __real_omega_so_oracles(uint64_t *,uint64_t,uint64_t,uint64_t,uint64_t,uint64_t); |
| 6 | uint32_t __wrap_omega_so_oracles(uint64_t *out,uint64_t op,uint64_t a,uint64_t b,uint64_t c,uint64_t d) { |
| 7 | uint32_t rc=__real_omega_so_oracles(out,op,a,b,c,d); |
| 8 | const char *red=getenv("SO_RED_OP"); |
| 9 | if(!rc && red && op==strtoul(red,NULL,0))*out=!*out; |
| 10 | return rc; |
| 11 | } |