Example #1
0
void func_compile_to_object0(h::Func &that, const std::string &filename,
                              const std::vector<h::Argument> &args,
                              const std::string fn_name = "",
                              const h::Target &target = h::get_target_from_environment())
{
    that.compile_to_object(filename, args, fn_name, target);
    return;
}
Example #2
0
File: main.cpp Project: halide/atom
int main(int argc, char **argv) {
    Halide::Func theFunc = getFunction();

    if (argc >= 3) {
        std::vector<Halide::Argument> arguments = theFunc.infer_arguments();

        Halide::Target target = Halide::get_target_from_environment();
        target.set_feature(Halide::Target::Feature::UserContext);

        theFunc.compile_to_object(argv[1] + std::string(".o"), arguments, argv[2], target);

        return 0;
    }

    return 1;
}