1 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
2 // See https://llvm.org/LICENSE.txt for license information.
3 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
5 // abs(x) < 0 and y == Const puzzle, 64-bit variant.
12 extern "C" int LLVMFuzzerTestOneInput(const uint8_t *Data
, size_t Size
) {
13 if (Size
< 16) return 0;
16 memcpy(&x
, Data
, sizeof(x
));
17 memcpy(&y
, Data
+ sizeof(x
), sizeof(y
));
18 volatile int64_t abs_x
= llabs(x
);
19 if (abs_x
< 0 && y
== 0xbaddcafedeadbeefULL
) {
20 printf("BINGO; Found the target, exiting; x = 0x%lx y 0x%lx\n", x
, y
);