//===--- mlir-text-parser-fuzzer.cpp - Entry point to parser fuzzer -------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===----------------------------------------------------------------------===// // // Implementation of main so we can build and test without linking libFuzzer. // //===----------------------------------------------------------------------===// #include "mlir/IR/BuiltinOps.h" #include "mlir/IR/Diagnostics.h" #include "mlir/IR/MLIRContext.h" #include "mlir/Parser/Parser.h" #include "llvm/ADT/StringRef.h" #include "llvm/Support/Compiler.h" usingnamespacemlir; extern "C" LLVM_ATTRIBUTE_USED int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) { … } extern "C" LLVM_ATTRIBUTE_USED int llvmFuzzerInitialize(int *argc, char ***argv) { … }