ks.c.j2 692 字节
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
{% from "operator_utils.c.j2" import name_map, register_name_map, register_base_kernel_name %}
// this file is generated by paddle/phi/op/yaml/generator/generate_op.py, do not edit.
#include "paddle/phi/core/compat/op_utils.h"
#include "paddle/utils/small_vector.h"

namespace phi {

{% for op in ops %}
  {% if op is base_op %}
{{name_map(op)}}
  {% endif %}
{% endfor %}
{% for op in backward_ops %}
  {% if op is base_op %}
{{name_map(op)}}
  {% endif %}
{% endfor %}
}  // namespace phi

{% for op in ops + backward_ops %}
  {% if op["name"] != op["op_name"] %}
{{register_base_kernel_name(op)}}
  {% endif %}
  {% if op is base_op %}
{{register_name_map(op)}}
  {% endif %}
{% endfor %}