Revision 22868a4db5f3a3a142ed7bc457fd9fd9ee6bdd76 authored by Prasoon Mishra on 06 March 2024, 21:40:00 UTC, committed by GitHub on 06 March 2024, 21:40:00 UTC
* Add sobel in hexagon_benchmarks app for CMake builds Resolved compilation errors caused by the eliminate interleave pass, which changed the instruction from halide.hexagon.pack_satub.vuh to halide.hexagon.trunc_satub.vuh. The latter is only available in v65 or later. This commit ensures compatibility with v65 and later versions. * Minor fix to address the issue. --------- Co-authored-by: Steven Johnson <srj@google.com>
1 parent 754e6ec
Deserialization.h
#ifndef HALIDE_DESERIALIZATION_H
#define HALIDE_DESERIALIZATION_H
#include "Pipeline.h"
#include <istream>
#include <string>
namespace Halide {
/// @brief Deserialize a Halide pipeline from a file.
/// @param filename The location of the file to deserialize. Must use .hlpipe extension.
/// @param user_params Map of named input/output parameters to bind with the resulting pipeline (used to avoid deserializing specific objects and enable the use of externally defined ones instead).
/// @return Returns a newly constructed deserialized Pipeline object/
Pipeline deserialize_pipeline(const std::string &filename, const std::map<std::string, Parameter> &user_params);
/// @brief Deserialize a Halide pipeline from an input stream.
/// @param in The input stream to read from containing a serialized Halide pipeline
/// @param user_params Map of named input/output parameters to bind with the resulting pipeline (used to avoid deserializing specific objects and enable the use of externally defined ones instead).
/// @return Returns a newly constructed deserialized Pipeline object/
Pipeline deserialize_pipeline(std::istream &in, const std::map<std::string, Parameter> &user_params);
/// @brief Deserialize a Halide pipeline from a byte buffer containing a serizalized pipeline in binary format
/// @param data The data buffer containing a serialized Halide pipeline
/// @param user_params Map of named input/output parameters to bind with the resulting pipeline (used to avoid deserializing specific objects and enable the use of externally defined ones instead).
/// @return Returns a newly constructed deserialized Pipeline object/
Pipeline deserialize_pipeline(const std::vector<uint8_t> &data, const std::map<std::string, Parameter> &user_params);
/// @brief Deserialize the extenal parameters for the Halide pipeline from a file.
/// This method allows a minimal deserialization of just the external pipeline parameters, so they can be
/// remapped and overridden with user parameters prior to deserializing the pipeline definition.
/// @param filename The location of the file to deserialize. Must use .hlpipe extension.
/// @return Returns a map containing the names and description of external parameters referenced in the pipeline
std::map<std::string, Parameter> deserialize_parameters(const std::string &filename);
/// @brief Deserialize the extenal parameters for the Halide pipeline from input stream.
/// This method allows a minimal deserialization of just the external pipeline parameters, so they can be
/// remapped and overridden with user parameters prior to deserializing the pipeline definition.
/// @param in The input stream to read from containing a serialized Halide pipeline
/// @return Returns a map containing the names and description of external parameters referenced in the pipeline
std::map<std::string, Parameter> deserialize_parameters(std::istream &in);
/// @brief Deserialize the extenal parameters for the Halide pipeline from a byte buffer containing a serialized
/// pipeline in binary format. This method allows a minimal deserialization of just the external pipeline
/// parameters, so they can be remapped and overridden with user parameters prior to deserializing the
/// pipeline definition.
/// @param data The data buffer containing a serialized Halide pipeline
/// @return Returns a map containing the names and description of external parameters referenced in the pipeline
std::map<std::string, Parameter> deserialize_parameters(const std::vector<uint8_t> &data);
} // namespace Halide
#endif
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...