blob: 3682a0cac2281da98295fe8a0f78341d69920218 [file] [log] [blame] [edit]
// Copyright 2021 The Tint Authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
syntax = "proto3";
package tint.fuzzers.ast_fuzzer.protobufs;
message Mutation {
oneof mutation { MutationReplaceIdentifier replace_identifier = 1; };
}
message MutationSequence {
repeated Mutation mutation = 1;
}
message MutatorState {
// Contains the state of the fuzzer.
// The program that is being fuzzed. This can be either
// the original program (if mutation sequence is available) or
// the mutated version (if mutations are being recorded).
string program = 1;
// The sequence of mutations that was applied to the `program`.
// This may not have any mutations if they are not being recorded.
MutationSequence mutation_sequence = 2;
}
message MutationReplaceIdentifier {
// This transformation replaces a use of one variable with another.
// The id of the use of a variable in the AST.
uint32 use_id = 1;
// The id of a definition of a variable to replace the use with.
uint32 replacement_id = 2;
}