Details

    • Type: Sub-task
    • Status: Open
    • Priority: P3
    • Resolution: Unresolved
    • Affects Version/s: repo-panama
    • Fix Version/s: repo-panama
    • Component/s: hotspot
    • Labels:

      Description

      Some ideas how to improve C2 part:

      (1) Turn vector stores on freshly allocated vector box into initializing stores.


      (2) Consider adding basic type-specific vector node variants: e.g., AddReductionVI => AddReductionVB/AddReductionVS/AddReductionVI

      It should simplify AD-rules and make IR representation more descriptive:

      instruct rsadd8B_reduction_reg(rRegI dst, rRegI src1, vecD src2, regF tmp, rRegI tmp2) %{
        predicate(UseSSE > 3 && n->in(2)->bottom_type()->is_vect()->element_basic_type() == T_BYTE);
        match(Set dst (AddReductionVI src1 src2));


      (3) Enhance argument parsing for generalized intrinsics.

      Every generalized intrinsic extracts static information from arguments. Right now it is quite elaborate and is duplicated. Consider adding some helper methods to simplify it.

      bool LibraryCallKit::inline_vector_nary_operation(int n) {
        const TypeInt* opr = gvn().type(argument(0))->is_int();
        const TypeInstPtr* vector_klass = gvn().type(argument(1))->is_instptr();
        const TypeInstPtr* elem_klass = gvn().type(argument(2))->is_instptr();
        const TypeInt* vlen = gvn().type(argument(3))->is_int();

        if (!opr->is_con() || vector_klass->const_oop() == NULL || elem_klass->const_oop() == NULL || !vlen->is_con()) {
          return false; // not enough info for intrinsification
        }
        ciType* elem_type = elem_klass->const_oop()->as_instance()->java_mirror_type();
        if (!elem_type->is_primitive_type()) {
          return false; // should be primitive type
        }

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            vlivanov Vladimir Ivanov
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated: